Deleting cookies and changing user agent in Python 3+ without Mechanize
<p>How do I delete cookies from a web browser and change the user agent in Python 3+ without using mechanize? I'm not going to be accessing the web through Python, I would just like my browser (Firefox or Chrome) to delete cookies and change my user agent for example at every startup (I can do the startup bit, just not the rest!)</p>

<p>set the <code>Expires</code> attribute to a date in the past (like Epoch):</p>

<pre><code>Set-Cookie: name=val; expires=Thu, 01 Jan 1970 00:00:00 GMT
</code></pre>

<p>Read more here:
<a href="http://stackoverflow.com/questions/5285940/correct-way-to-delete-cookies-server-side">Correct way to delete cookies server-side</a></p>

python python-3.x cookies user-agent