The XML Declaration:

The XML declaration is a processing instruction that identifies the document as being XML. All XML documents should begin with an XML declaration.

<?xml version="version_number" encoding="encoding_declaration" standalone="standalone_status" ?>

Example:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>

Rules:

Note:

The following table shows a list of the possible attributes that may be used in the XML declaration.

Attribute name:Possible attribute value:Attribute description:
version1.0Specifies the version of the XML standard that the XML document conforms to. The version attribute must be included if the XML declaration is declaredwell-formedness constraint.
encodingUTF-8, UTF-16, ISO-10646-UCS-2, ISO-10646-UCS-4, ISO-8859-1 to ISO-8859-9, ISO-2022-JP, Shift_JIS, EUC-JPThese are the encoding namesglossary of the most common character sets in use today. For a full list of encodings check the IANA'sglossary website.
standaloneyes, noUse 'yes' if the XML document has an internal DTD. Use 'no' if the XML document is linked to an external DTD, or any external entity referencesvalidity constraint.