Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Frontend GIS
  3. Proj4js

Proj4js

NOASSERTIONJavaScriptv2.20.9

A JavaScript library for transforming point coordinates between different coordinate systems and datums.

Visit WebsiteGitHubGitHub
2.2k stars349 forks0 contributors

What is Proj4js?

Proj4js is a JavaScript library that transforms point coordinates from one coordinate reference system to another, including datum transformations. It is a port of the PROJ library, enabling accurate geospatial conversions in web and Node.js applications. The library supports a wide range of projections, grid-based adjustments, and flexible input formats.

Target Audience

Developers working with geospatial data in web mapping applications, GIS tools, or data processing pipelines who need to convert coordinates between different coordinate systems and datums.

Value Proposition

Proj4js provides a reliable, battle-tested coordinate transformation library for JavaScript, derived from the industry-standard PROJ. It offers extensive projection support, datum transformations, and grid-based adjustments, making it the go-to solution for accurate geospatial conversions in the browser and Node.js.

Overview

JavaScript library to transform coordinates from one coordinate system to another, including datum transformations

Use Cases

Best For

  • Converting latitude/longitude coordinates to UTM or other projected coordinate systems
  • Transforming geospatial data between different datums (e.g., NAD83 to WGS84)
  • Integrating coordinate conversion into web mapping applications like Leaflet or OpenLayers
  • Processing GIS data in Node.js that requires projection changes
  • Handling EPSG code transformations in JavaScript applications
  • Applying high-precision grid-based datum adjustments (NTv2, GeoTIFF) to coordinates

Not Ideal For

  • Applications requiring real-time, high-throughput coordinate transformations on massive datasets (e.g., processing millions of points per second), as JavaScript performance may be limiting.
  • Projects that only need basic Web Mercator (EPSG:3857) to WGS84 (EPSG:4326) conversions, where lighter alternatives like simple utility functions could suffice.
  • Teams seeking an all-in-one GIS solution with built-in map visualization, spatial analysis, or data editing capabilities, as Proj4js focuses solely on coordinate conversion.
  • Environments with strict memory constraints, since loading large grid files (e.g., NTv2 .gsb) for high-precision adjustments can be resource-intensive.

Pros & Cons

Pros

Extensive Projection Support

Supports hundreds of projections via PROJ strings, WKT, and PROJJSON, with predefined EPSG codes like EPSG:4326 and UTM zones, allowing flexible conversions for diverse geospatial workflows.

Accurate Datum Transformations

Includes built-in Helmert transformations for many datums and supports grid-based adjustments (NTv2, GeoTIFF) via external files, enabling high-precision conversions as detailed in the README's nadgrid examples.

Flexible API Design

Accepts coordinates as arrays [x,y] or objects {x,y}, with optional elevation (z) and measure (m) values, and allows axis order control, making it adaptable to various input formats.

PROJ Library Port

Derived from the industry-standard PROJ library, ensuring robust, battle-tested accuracy for coordinate transformations, which is critical for GIS and mapping applications.

Cons

Complex Grid File Setup

Using high-precision grid adjustments requires managing external files (e.g., NTv2 .gsb or GeoTIFF .tif) and additional libraries like GeoTIFF.js, adding setup overhead and potential dependency issues.

Precision Limitations

Conversions can introduce floating-point errors, as noted in the README example where inverse projection yields 40.99999999999986 instead of 41, which may affect accuracy-sensitive applications.

Steep Learning Curve

Requires understanding of PROJ strings, WKT, and coordinate system concepts, with limited beginner-friendly documentation, making it challenging for developers new to geospatial data.

Performance Trade-offs

JavaScript-based transformations may be slower for intensive computations compared to native C/C++ libraries, especially when handling large datasets or complex grid-based adjustments.

Frequently Asked Questions

Quick Stats

Stars2,230
Forks349
Contributors0
Open Issues100
Last commit19 hours ago
CreatedSince 2013

Tags

#web-mapping#geospatial#epsg#utm#gis#javascript-library#projections#javascript#coordinate-transformation

Built With

J
JavaScript
N
Node.js

Links & Resources

Website

Included in

Frontend GIS675
Auto-fetched 19 hours ago

Related Projects

Turf.jsTurf.js

A modular geospatial engine written in JavaScript and TypeScript

Stars10,415
Forks1,014
Last commit1 day ago
topoJSONtopoJSON

An extension of GeoJSON that encodes topology! 🌐

Stars4,903
Forks683
Last commit1 year ago
geolibgeolib

Zero dependency library to provide some basic geo functions

Stars4,277
Forks336
Last commit3 months ago
rbushrbush

RBush — a high-performance JavaScript R-tree-based 2D spatial index for points and rectangles

Stars2,759
Forks253
Last commit3 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub