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

How can i display two layers with diferent projections at once? For example i have layer with EPSG:70076 and OSM layer.

share|improve this question
what sort of layers (vector/raster)? what is the source of the layer (wms, wfs, tile cache, google...)? what code have you tried already? – iant Apr 30 '12 at 9:55
1 vector layers 2 wms and OSM 3 Im find example on openlayers site but this reproject all map. – Kliver Max Apr 30 '12 at 9:59
[code]var options = { projection: new OpenLayers.Projection("EPSG:900913"), displayProjection: new OpenLayers.Projection("EPSG:4326") }; map = new OpenLayers.Map('map', options);[/code] This example from openlayers site. How reproject layers with diferent projections? – Kliver Max Apr 30 '12 at 10:01
im try do like in this example but OSM layer display – Kliver Max Apr 30 '12 at 10:14
can you edit those comments into the question – iant Apr 30 '12 at 10:17
up vote 3 down vote accepted

To add two raster layer on the same map like you say in the previous link:

  • Both layer must be set isBaseLayer to false so they were overlay layers.
  • Use the projection property in the map or on each layer.

OSM by default is EPSG:900913 while for a WMS layer you can use any projection the WMS server accepts, so ensure the server accepts the projection you are requesting.

Maybe not necessary to say but remember you can't have a map with a layer in a projection A and a second layer with a projection B.


share|improve this answer
Okay. I set Declared SRS 900913 to WMS layer. But nothing changes. OSM not displaying it look like this screenshot. – Kliver Max Apr 30 '12 at 13:22
put your code, please. You can use something like to share it – EricSonaron Apr 30 '12 at 15:51
You probably need to explicity add the proj4js library. OpenLayers only has native support for common formats like 900913. See the example here: Also, see the userguide on the proj4js page to see how it is done. – John Barça Jan 30 '13 at 8:45

Generally, if you have WMS with different projections, you need to deal with this at the server level. Reprojecting tiles on the client will be slow, and unless they have similar projection properties, will probably look awful too (as reprojection usually involves resampling and rotation). If you control the generation of the tiles on the server, then you can reproject at source to a common projection, such as 900913 (geoserver does this, for example).

If you want to reproject vectors, as distinct from rasters, then you can do this client side, but you will probably need to add the proj4js library, as openlayers only natively supports 900913 and 4326. See the example here: Also, see the userguide on the proj4js page to see how it is done. proj4js/

share|improve this answer

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.