B2G/User Agent/Device Model Inclusion Requirements
Adding a device identifier to the Firefox OS User Agent (UA) string is STRONGLY DISCOURAGED by Mozilla. As studies have shown, changes to the UA string have a negative impact on web compatibility - some major websites will stop working if you do this! Further reasons are documented in the Firefox OS User Agent Partner Changes Policy.
If a device/model ID is nevertheless to be added in contravention of our advice, then the UA with a device/model ID should be of the form:
Mozilla/5.0 (Mobile; XXXX; rv:18.0) Gecko/18.0 Firefox/18.0
where XXXX represents the device model identifier.
Note: Occurrences of "18.0" will not necessarily be "18.0". This number should be whatever number is in the default UA string for the Firefox OS version being shipped.
Specific requirements for the device identifier ("XXXX")
- Use a simple token. For example, "NexusOne" or "ZTEOpen". Do not use slash ("/"), semicolon (";"), round brackets or any whitespace. It is recommended that you use only letters (“A-Za-z”), numbers (“0-9”), hyphen (“-”) and dot (“.”). Shorter is better.
- The device model identifier should always be the same for a particular device, and should stay the same for a successor or sibling device unless the hardware configuration is different in a way relevant to the web (i.e. not just a different chipset). Indicate the difference between devices with the same brand name but different hardware configurations using a more complete name, such as “HTCOne”, “HTCOneX”, and “HTCOneXPlus”, or a numeric identifier such as “ZTEOpen”, “ZTEOpen2”, and “ZTEOpen3”. Remember that this string is not user-visible so does not need to match your branding strategy.
- Do not include a "build id" in addition to the device name. This will simply damage web compatibility.