I was actually struggling with this same problem this past month. You should use: var xmlResponse = new OpenLayers.Format.XML().read(response.responseText); this will convert the text into a valid xml object.