Craft 2: Serve language / locale i18n according to user agent As the official documentation does not give any hints on this:

I am wondering how to serve the correct localization of my website according to the user’s language preference and/or browser/OS language with Craft. 

From other platforms/plugins I know that this is done through user agent detection, e.g. if the browser/OS is English you’ll get the EN, if it’s Spanish you’ll get the ES version of the content, etc.

The project I am working on has DE as the primary locale and the language switcher shall only appear subtly within the footer. Non-German visitors should automatically get the EN version without having to interact with any interface element.

How can I implement this?
You could accomplish this before your PHP is executed as redirects listening for the accept_language header (both are untested from my part):

APACHE

RewriteEngine on
RewriteCond %{HTTP:Accept-Language} (de) [NC]
RewriteRule .* http://example.com/de/ [R,L]


NGINX

map $http_accept_language $lang {
  default en;
  ~de de;
}

location ~* "/" {
  return 302 https://example.com/$lang;
}