GIS Tools

Language

Made withfor the GIS community

Layer Styler

Adjust opacity, stroke width, colors, and dashed lines

Map Viewing

Add GeoJSON layers

Drop multiple files

Tips

  • Opacity: Adjust fill transparency
  • Stroke: Control outline thickness (1-10px)
  • Dashed: Toggle dashed line pattern
  • Colors: Click swatch to change color
  • Order: Use arrows to reorder layers

What Is a Layer Styler?

A layer styler is the GIS equivalent of a paintbrush and palette: a UI that lets you set the visual properties of a map layer β€” fill color, stroke color, stroke width, dash pattern, opacity, point radius β€” without touching code or CSS. Every serious GIS platform ships one, from QGIS's Symbology panel to ArcGIS Pro's Appearance tab to Mapbox Studio's style editor. The gis.tools layer styler brings that experience to the browser with drag-and-drop simplicity.

Opacity and blending are the most underappreciated styling controls. Adjusting opacity transforms an opaque polygon layer into a transparent overlay that reveals the basemap underneath, and layering multiple translucent layers produces the cumulative density effects you see in sophisticated thematic maps. Stroke width and dash patterns let you distinguish proposed versus existing features in planning maps, or draw boundaries at different priorities.

This tool focuses on simple, direct styling β€” one style applied uniformly to a whole layer β€” which is what you need 80% of the time. For data-driven styling (different colors based on attribute values), reach for the Categorical Styling or Graduated Styling tools instead.

How Layer Styling Works

The style specification

Under the hood, every styled layer stores a small JSON object describing its visual properties with keys like fill, fillOpacity, stroke, strokeWidth, and strokeDasharray. When you move a slider or pick a color, the styler updates this object in memory and re-renders the layer in real time. The style is never baked into the geometry file; it is metadata applied at paint time, which means you can tweak freely without touching the underlying GeoJSON.

Alpha compositing

Layer opacity works via alpha compositing: each pixel on the canvas is a blend of the layer's color and whatever was drawn below it. The formula is roughly output = src.rgb Γ— src.alpha + dest.rgb Γ— (1 - src.alpha). That is why stacking two 50% opacity blue layers produces a darker blue where they overlap β€” the mathematics of additive blending.

Stroke joins and caps

For line features, stroke style includes parameters beyond color: line cap (butt, round, square), line join (miter, round, bevel), and dash array (the pattern of filled and empty segments). These details matter for publication-quality cartography; sharp miter joins look precise on large-scale engineering maps, while round joins are softer and more appropriate for social or political boundaries.

Key Parameters and Options

Fill color

For polygons, the fill color is the main attention-grabber. Choose a color that contrasts with your basemap and is distinguishable for colorblind viewers. ColorBrewer palettes (developed by Cindy Brewer at Penn State) are the gold standard for cartographic color choice and are built into most professional GIS tools.

Fill opacity

A value from 0 (transparent) to 1 (opaque). For overlay layers, values between 0.3 and 0.7 usually produce the best balance between foreground emphasis and basemap visibility.

Stroke color

The outline color for polygons and the main color for lines. A slightly darker shade of the fill color creates a subtle border; a contrasting color (black or white) produces a bolder edge.

Stroke width

Measured in pixels. For small-scale maps (zoomed out), 0.5–1 px is usually enough; for large-scale detail maps, 1.5–3 px gives strokes visual weight.

Dash pattern

A sequence of numbers like 4 2 meaning 4 pixels on, 2 pixels off, repeat. Useful for signaling uncertainty, proposed features, or administrative vs physical boundaries.

Point radius

For point features, the circle radius in pixels. Typical values range from 3 (small reference markers) to 15 (emphasized highlights).

Practical Applications

Urban planning map sets

A planning consultancy preparing a community master plan will stack many layers: existing parcels, proposed zoning changes, street network, open space, historic buildings, environmental constraints. Each needs a distinct visual identity. Fill opacity around 0.4 lets the basemap street network show through, while crisp 2 px strokes delineate each polygon. Dashed lines separate proposed from existing features. A good layer styler is essential for producing a legible plan.

Conservation and habitat mapping

Ecologists overlay multiple species range polygons to identify biodiversity hotspots. Each range is styled with a low-opacity fill of a distinct color. Where three or four ranges overlap, the alpha compositing produces a darker, richer color that visually marks the hotspot without any extra computation.

Emergency and risk visualization

Floodplain maps typically use a semi-transparent blue for the 100-year floodplain and a slightly darker blue for the 500-year floodplain, layered so the 100-year zone appears deeper. Stroke-only polygons with no fill identify protection zones or evacuation routes without obscuring the underlying terrain.

Transportation network visualization

Road networks benefit enormously from data-driven styling, but for simple visualization tasks you might just want motorways in red, arterials in orange, locals in gray. A layer styler handles that in seconds.

Real estate and site selection

A real estate analyst comparing candidate retail sites will style buffer rings around each candidate, overlay demographic polygons with 30% opacity, and outline the study area with a dashed boundary. The final deliverable is a PDF that only exists because the styler made it quick.

Publication cartography

Academic journals have strict style guides for maps. A good styler lets you match journal requirements (e.g., 0.5 pt strokes, grayscale fills, no transparency) without leaving the browser.

Step-by-Step Workflow

  1. Load your data in the Online Map Viewer (Multi-Layer).
  2. Select the layer you want to restyle from the layer list.
  3. Open the layer styler panel.
  4. Adjust fill color via the color picker. Try several colors to find one that contrasts with the basemap.
  5. Move the opacity slider. Watch the underlying basemap and other layers shift in and out of prominence.
  6. Set stroke color and width. For bold maps, 2 px; for subtle maps, 0.5 px.
  7. Optionally add a dash pattern for proposed or secondary features.
  8. For point layers, set the radius.
  9. Your changes apply in real time. Repeat for each layer.
  10. Export the styled map using the Print Composer or save the project state with the GIS Notebook.

Common Pitfalls and Gotchas

  • Fully opaque layers hiding context. If you set fillOpacity to 1.0, the basemap disappears under the polygon. Always test at 0.4–0.6 first.
  • Colors clashing with the basemap. A bright yellow overlay on a light OSM basemap is nearly invisible. Pair fill color with an appropriate Basemap Switcher choice.
  • Stroke width scaling. Strokes stay the same pixel width regardless of zoom, which looks wrong at very high or very low zoom. Some tools offer scale with zoom modes; the gis.tools styler keeps strokes at a constant pixel width.
  • Too many styles on one map. Beyond about 5–7 distinguishable colors, the map becomes unreadable. Use Categorical Styling with grouping or aggregate to a coarser classification.
  • Dash patterns at small widths. A 2 2 dash pattern at 1 px stroke looks like a dotted line; at 3 px it looks like dashes. Scale the dash array proportionally to the stroke width.
  • Color blindness. Avoid red/green-only distinctions. Use ColorBrewer-safe palettes or verify with a simulator.

Tips for Best Results

  • Start with a neutral basemap. Dark matter or light Positron from CartoDB lets your chosen colors shine without competing.
  • Use ColorBrewer palettes from colorbrewer2.org β€” they are vetted for perceptual uniformity and colorblind safety.
  • Keep strokes thin on dense layers. Thick strokes merge visually when polygons are small and numerous.
  • Match opacity to layer importance. The most important layer should be most opaque; context layers stay at 0.3.
  • Export a legend using the Symbology Editor and Print Composer.
  • Use a monochrome palette for single-variable maps. Complex palettes confuse readers.
  • Preview on multiple devices. What looks good on a calibrated monitor may look murky on a phone.

Comparison with Desktop GIS Stylers

QGIS's Layer Styling panel and Symbology tab offer everything this tool does and more: rule-based styling, data-defined overrides, per-zoom-level styles, SVG symbol import, pattern fills, and geometry generators. ArcGIS Pro's Symbology tab is similarly deep. Both require a desktop installation and a project file.

The gis.tools layer styler is designed for quick, single-pass styling of a layer you loaded five minutes ago. It is not a replacement for a desktop styling environment when you are producing cartographically sophisticated output, but it covers the core cases that cover 80% of practical work. For more advanced data-driven styling, chain it with Categorical Styling or Graduated Styling.

Performance Considerations

Layer styling is essentially free from a performance perspective. Changing a color or opacity value simply updates a uniform in the WebGL shader and triggers a re-render. You can drag a color slider at 60 fps on layers with tens of thousands of features. The one exception is when you are styling data-driven properties that require evaluating every feature's attributes β€” that is better handled by the dedicated Graduated Styling tool.

Data Privacy and Browser-Based Processing

All styling happens in your browser. No style choices, no color picks, no opacity slider movements are ever sent to a server. The style metadata stays local and travels with your project only if you explicitly save it via the GIS Notebook or Layer Packaging Tool.

Related GIS Concepts

Simple Style Specification. A minimalist GeoJSON extension that encodes basic style properties in feature metadata. The gis.tools styler can import and export this format.

Mapbox Style Specification. A much richer JSON schema describing every aspect of a vector tile style, including zoom-dependent values, data-driven expressions, and layer types. Convert between simple and Mapbox styles with the Map Style Converter.

SLD (Styled Layer Descriptor). An OGC XML standard for styling WMS and WFS layers, supported by GeoServer and MapServer but rarely seen in pure web-native workflows.

Frequently Asked Questions

Can I save my style and reuse it on another layer?

Yes β€” use the Layer Packaging Tool or GIS Notebook to save a project bundle. You can also export the style JSON via the Map Style Converter.

Why is my layer invisible?

The most common causes are 100% transparency, a color that matches the basemap, or the layer being hidden behind another opaque layer. Check the layer list and opacity slider.

Can I style individual features differently?

Not with this tool β€” the layer styler applies a single style to the whole layer. Use Categorical Styling or Symbology Editor for per-feature styling.

How do I get a legend?

Use the Symbology Editor to define labeled style rules, then generate a legend with the Print Composer.

Related Tools on gis.tools

100% client-side processing - your data stays private and never leaves your device