Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to use the XYtools plugin to read an Excel file. After choosing the XYtools incon and indicating an Excel file to read in, a message appears "there is a problem with loading a python module which is needed to read/write Excel files. ... see documentation/help on how to install the xlw and xlwd libraries." I found the site where the Python items reside but I cannot understand at all what to do next. Apparently the needed Python libraries are not installed with XYtools. I would appreciate being pointed to somewhere that might give some help with exactly what to do to get XYtools to work with Excel files.
Thanks -

share|improve this question
up vote 4 down vote accepted

To continue the suggestion by Alister on the qgis-users maillist, since you've installed using the OSGeo4W installer, then just

  • rerun the osgeo-setup.exe, and choose "Advanced Install" in the first window.
  • Click Next->Next a few times till you get to the "Select Packages" window.
  • Here you click on the '+' in the Libs section to open the full list. Scroll down to find the python-xlrd and python-xlwt packages, and select them to be installed (click on the double cirular arrow symbol).
  • After it finishes, open QGIS, and try the XYTools plugin. Should be OK...
share|improve this answer
That worked! Thanks a lot! I can read in the Excel file. – HealthMaps Aug 12 '12 at 8:13
When the Excel file was read in with XYtools all the columns that were numerical in Excel are text in the temporary layer. This seems to be a real downside to QGIS to read in numerical data as text and then have to convert. What is the reason for this? – HealthMaps Aug 12 '12 at 8:19
@HealthMaps Have a look at Shepherdjo's response here Er... nevermind, you've obviously seen that one. – nagytech Aug 12 '12 at 8:57
For the record: on Linux systems (here, Fedora), install them as this: yum install python-xlwt python-xlrd – markusN Aug 14 '12 at 12:05
also just for the record. On windows with qgis 1.8 standalone installer: just extract the two archives *.gz (from and and copy the folders xlrd and xlwt into your qgis at c:\program files(x86)\quantumGIS Lisboa\apps\Python27\Lib and install afterwards xytools ... – Kurt Sep 16 '12 at 17:53

XY Tools requires extra Python modules to be installed before some of its features will work. The xlw and xlrd modules can be installed via normal Python package/module methods, which will generally install in your system's site-packages for Python.

Using pip is probably your best bet. First install pip, then install the noted packages. Relaunch QGIS to test for proper loading of plugin. QGIS will find installed modules from normal Python system paths.

share|improve this answer
Great! But I found out now that python-xlw have changed to pyton-xlwt /Cheers – user10236 Sep 15 '12 at 14:47

FYI: There is also FreeXL which might be integrated into QGIS.

FreeXL is an open source library to extract valid data from within an Excel (.xls) spreadsheet.

share|improve this answer
The routine in XYtools is set up for making a point layer from an Excel file that has X & Y coordinates, like locations of disease cases with various attributes. If one has no X & Y coordinates then it will make one up for you (one X and one Y) so that you get a point vector file. It looks like FreeXL is/can be integrated into Spatialite which (i guess) means one could read in a Excel file that is not intended for a point file as an attribute file for use later. Don't know much about Spatialite. – HealthMaps Aug 13 '12 at 7:14

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.