Visual Studio ships with a tool called Xsd.exe that will automatically generate XSD based on an XML file. To use Xsd.exe, you will need to open up a Visual Studio command prompt. Click “Start,” point to “All Programs,” point to “Microsoft Visual Studio