Are you trying to or set up language detection for a specific web application? The role of Accept-Language header in software localization
A full header might look like this: Accept-Language: en-US,en;q=0.9,fr-FR;q=0.8 This tells the server: "I prefer US English (1.0), but I'll take any English (0.9) or French from France (0.8) if that's what you have".
: If fr-FR is not available, it may look for a general French version ( fr ) or the next language in the user's priority list. 0.9,fr-FR
The string "0.9,fr-FR" is typically a segment of an , which tells a web server which languages a user prefers for the content they receive. Understanding the Syntax
: If the server has a French (France) version of the page, it will serve that. Are you trying to or set up language
In this context, the values indicate a prioritized list of preferences: : This specifies French as spoken in France .
: The "q" (quality value) is a weight from 0.0 to 1.0. A value of 0.9 indicates a high priority, though typically slightly lower than the primary language (which defaults to 1.0 if not specified). How Servers Use It The string "0
When a server receives this header, it attempts to match the request with available content: