The Java Spatial Index project aims to maintain a high performance Java version of the RTree spatial indexing algorithm. as described in the 1984 paper "R-trees: A Dynamic Index Structure for Spatial Searching" by Antonin Guttman. (PDF on CiteSeerX)

The code is open source, and released under the GNU Lesser General Public License, version 2.1 or later.

See the SourceForge project page for more information. Javadoc documentation is available online.


The JSI spatial index is deliberately limited in features, and does a small number of things well. It particular, it is fast. On a test machine, it takes about 500ms to add 10,000 entries to the spatial index. By comparison, an alternative implementation (that seems to be unmaintained now) takes over 6000ms (but it has more features).

The current release is 1.0.0, and binaries are available in a zip file at, or via a maven repository hosted at See for examples that use the JSI library via this maven repo.

The source is hosted at github, at Feel free to send pull requests. To build the source or run tests, you will need maven 2 (NOT maven 3) installed and a working internet connection. Note that the CVS and SVN repositories on sourceforge are well out of date.

The API includes the following operations:

  • Add
  • Delete
  • Intersection query
  • Nearest neighbour query
  • Nearest N neighbours query
  • Containment query Logo

YourKit is kindly supporting open source projects with its full-featured Java Profiler. YourKit, LLC is the creator of innovative and intelligent tools for profiling Java and .NET applications. Take a look at YourKit's leading software products: YourKit Java Profiler and YourKit .NET Profiler."