Skip to content
This repository

Functions and classes to access online data resources. Maintainer: @keflavich

branch: master

Merge pull request #306 from cdeil/issue_306

Fix Sphinx API docs links
latest commit cc1bb1abdc
Adam Ginsburg keflavich authored April 18, 2014
Octocat-spinner-32 astroquery Fix lots of sphinx formatting and links in docstrings April 18, 2014
Octocat-spinner-32 cextern Initial commit of affiliated package template December 22, 2011
Octocat-spinner-32 docs Turn nitpicky mode off in sphinx docs build April 18, 2014
Octocat-spinner-32 frontpage another and another and another try.... September 15, 2013
Octocat-spinner-32 licenses Imported schema with license. November 09, 2013
Octocat-spinner-32 scripts removed examples from package template June 25, 2012
Octocat-spinner-32 .gitignore update gitignore to include docs/api and astroquery.cfg January 05, 2014
Octocat-spinner-32 .travis.pip.wheel travis uses wheels for matplotlib, sphinx August 06, 2013
Octocat-spinner-32 .travis.yml astropy version stable->dev February 18, 2014
Octocat-spinner-32 CHANGES Back to development: 0.2 September 19, 2013
Octocat-spinner-32 CONTRIBUTING.rst documentation update for the new template module December 31, 2013
Octocat-spinner-32 a vain attempt to get data to install. I think this will not work. August 06, 2013
Octocat-spinner-32 README.rst Fix broken links in README April 16, 2014
Octocat-spinner-32 Switch to using, and simplify, following recent … September 29, 2013
Octocat-spinner-32 pip-requirements Added lxml and keyring to package requirements January 16, 2014
Octocat-spinner-32 pytest.ini pytest.ini uses --doctest-plus instead of --doctest-modules October 14, 2013
Octocat-spinner-32 setup.cfg Run doctests as part of python test October 14, 2013
Octocat-spinner-32 change install requirements April 18, 2014
Octocat-spinner-32 Switch to using, and simplify, following recent … September 29, 2013

Documentation | Blog | View on Github | Download Stable ZIP | Download Stable TAR

Accessing Online Astronomical Data

Astroquery is an astropy affiliated package that contains a collection of tools to access online Astronomical data. Each web service has its own sub-package. For example, to interface with the SIMBAD website, use the simbad sub-package:

>>> from astroquery.simbad import Simbad
>>> theta1c = Simbad.query_object('tet01 Ori C')
>>> theta1c.pprint()
   MAIN_ID          RA           DEC      ... COO_QUAL COO_WAVELENGTH     COO_BIBCODE
------------- ------------- ------------- ... -------- -------------- -------------------
* tet01 Ori C 05 35 16.4637 -05 23 22.848 ...        A              O 2007A&A...474..653V

Installation and Requirements

As an astropy affiliate, astroquery requires astropy. However, because astroquery relies heavily upon the astropy.coordinates module, the development version of astropy is required. astropy can be installed from pip:

$ pip install git+

astroquery uses the requests module to communicate with the internet. requests can also be installed with pip.

The first beta release of astroquery can be downloaded or pip installed:

$ pip install astroquery

Or if pypi is down:

$ pip install

If you'd like the latest development version, you can install it with the following commands:

$ git clone
$ cd astroquery
$ python install

pip install also works:

$ pip install git+

Using astroquery

Importing astroquery on its own doesn't get you much: you need to import each sub-module specifically. Check out the docs to find a list of the tools available. The API shows the standard suite of tools common to most modules, e.g. query_object and query_region.

To report bugs and request features, please use the issue tracker. Code contributions are very welcome, though we encourage you to follow the API and contributing guidelines as much as possible.

List of Modules

  • Simbad: Basic data, cross-identifications, bibliography and measurements for astronomical objects outside the solar system.
  • Vizier: Set of 11,000+ published, multiwavelength catalogues hosted by the CDS.
  • IRSA dust: Galactic dust reddening and extinction maps from IRAS 100 um data.
  • NED: NASA/IPAC Extragalactic Database. Multiwavelength data from both surveys and publications.
  • IRSA: NASA/IPAC Infrared Science Archive. Science products for all of NASA's infrared and sub-mm missions.
  • UKIDSS: UKIRT Infrared Deep Sky Survey. JHK images of 7500 sq deg. in the northern sky.
  • MAGPIS: Multi-Array Galactic Plane Imaging Survey. 6 and 20-cm radio images of the Galactic plane from the VLA.
  • NRAO: Science data archive of the National Radio Astronomy Observatory. VLA, JVLA, VLBA and GBT data products.
  • Besancon: Model of stellar population synthesis in the Galaxy.
  • NIST: National Institute of Standards and Technology (NIST) atomic lines database.
  • Fermi: Fermi gamma-ray telescope archive.
  • SDSS: Sloan Digital Sky Survey data, including optical images, spectra, and spectral templates.
  • Alfalfa: Arecibo Legacy Fast ALFA survey; extragalactic HI radio data.
  • SHA: Spitzer Heritage Archive; infrared data products from the Spitzer Space Telescope
  • Lamda: Leiden Atomic and Molecular Database; energy levels, radiative transitions, and collisional rates for astrophysically relevant atoms and molecules.
  • Ogle: Optical Gravitational Lensing Experiment III; information on interstellar extinction towards the Galactic bulge.
  • Splatalogue: National Radio Astronomy Observatory (NRAO)-maintained (mostly) molecular radio and millimeter line list service.

Additional Links

Download Development ZIP | Download Development TAR

Maintained by Adam Ginsburg (

To cite, use our figshare DOI (

Bitdeli badge
Something went wrong with that request. Please try again.