Online STL Slicer
NEW!

Online STL Slicer

Turn an STL, OBJ or 3MF into Marlin G-code in your browser: printer presets, walls, infill and a layer-by-layer preview. Nothing is uploaded.

3D Printing

Your model never leaves your browser. Slicing runs on your device.

Examples

Settings

Sparse infill is printed once every N layers, N times as thick; walls and skins are unchanged. It saves time with fine layers (0.08–0.12 mm); at 0.2 mm on a 0.4 nozzle it does not fit (max 0.75 × nozzle). The part is weaker: not for functional parts.

Thin layers where the surface is shallow, thick ones where it is vertical. Heights are kept between 0.1 and 0.75 × the nozzle (0.04–0.3 mm on a 0.4): below that the extruder cannot meter the flow, above it layers do not bond. There is one height for the whole bed, so a straight wall next to a dome prints fine too. Top and bottom layers are counted in millimetres (layer count × layer height).

20 %
Iron top surfaces

After the last layer of each top surface, the nozzle goes over it again with very close lines and very little plastic to leave it smooth. Adds print time.

Cooling and bridges

Layers that would print faster than the minimum time slow down so they can cool; stretches with nothing under them print as bridges, across the gap, with the fan at full.

Bed adhesion

A brim adds loops touching the first layer so it does not lift; a raft prints a base under the part, useful on uneven beds or for small parts.

Supports

Anything that sticks out further than the overhang angle is supported. Supports print as easy-to-remove lines, with a few dense layers right under the model.

Advanced

With Klipper, the start and end G-code are replaced by your macros (PRINT_START / PRINT_END), which heat and home on the printer.

Travels between two points of the same part go round inside it, without retracting: fewer strings and less time.

Colour change / pause

Your settings are kept in this browser. The file and the link carry the printer, material and settings, never the model.

These settings bring G-code for your printer

The G-code below will be sent to your printer as written. Read all of it, and apply it only if you trust whoever gave it to you. Source:

Keywords

online slicerstl to gcodeslicer onlinebrowser slicer3d printing slicergcode generatorartillery sidewinder x1 slicer

Need something else?

How to use

1

Drop an STL, OBJ or 3MF file onto the page, or open Examples and pick one of the built-in test shapes. The file is read in your browser and never leaves your device.

2

Place the model: rotate it in quarter turns around X, Y or Z and set the scale. It is centred on the bed and dropped onto it automatically, and the top view tells you straight away whether it fits your printer.

3

Choose your printer and material, then adjust layer height, walls, top and bottom layers, infill density and pattern. Speeds, retraction and temperatures are under Advanced.

4

Press Slice and step through the result layer by layer. Every path is coloured by type (skirt, outer wall, inner wall, skin, infill), so you can see exactly what the nozzle will do before any plastic is spent.

5

Check the estimated print time and filament, download the G-code and copy it to your printer's SD card or send it with your usual host software.

Features

Runs entirely in your browser

Parsing, slicing and G-code generation happen in a background worker on your own device. The page stays responsive while a large model is sliced, and the model itself is never sent anywhere.

Printer presets copied from Cura

Artillery Sidewinder X1 (the default), Creality Ender-3 and Ender-3 v2, Ender-3 V3 SE and Prusa i3 MK3/MK3S: bed size, retraction, acceleration and the start and end G-code of each come from Ultimaker Cura's public definition of that printer, not from guesswork. A generic Marlin profile (220 × 220 mm bed, a minimal home-and-reset start sequence) covers other machines.

Layer-by-layer preview

A top view of every layer with each path coloured by type. Zoom, pan and move through layers with the keyboard or by dragging, and check that thin features still get a wall and top surfaces get a solid skin.

Walls, skins and infill under your control

Set the number of walls, top and bottom layers, infill density from 0 to 100 % and a lines or grid pattern. Every change shows up in the preview after the next slice, so the effect of each setting is visible, not theoretical.

Print time and filament estimate

The same move list that is written to the G-code is timed with your printer's acceleration and jerk, and the filament length is converted into grams using the material's density, so you know roughly how long and how much before you start.

Why Choose This Tool?

Your model never leaves your device

Cloud slicers upload your file to a server to process it. Here the slicing engine runs inside the browser tab, so a client's prototype, a part under NDA or a design you have not released stays on your machine. There is no account, no upload and no copy kept anywhere.

No installation, on any computer

Desktop slicers are excellent, but they have to be installed, updated and configured. This works on a borrowed laptop, a locked-down work PC or a Chromebook: open the page, drop the model, download the G-code.

Honest about what it does

The engine is small and every step is explained on this page, from where each layer is cut to how much filament each line pushes. There are no magic defaults you cannot see: small gaps in the outline are closed, as explained below, and anything larger, or features too thin to print, gets a warning naming the layers affected.

G-code you can read

The output uses the same comment markers as Cura (layer numbers, path types, layer count and print time), relative extrusion and one move per line. Any G-code viewer or printer host that understands Cura files will show it correctly, and you can open it in a text editor and follow it.

How a slicer turns an STL into G-code

An STL file describes only the surface of an object: a list of triangles, each with three corners. A 3D printer cannot use that directly. It needs to be told, line by line, where to move the nozzle and how much plastic to push while it moves. The program that bridges the two is the slicer, and this page describes step by step what this particular slicer does with your model. It is a small engine written for the browser, and every stage below is the actual method used, not a generic textbook description.

1. Cutting the model into layers

The model is first placed on the bed: rotated in quarter turns, scaled, centred and lowered until its lowest point touches the plate. Then it is cut by horizontal planes, one per layer. Each layer is a slab between two heights, and the cut is made at the middle of the slab, not at its top or bottom. With a 0.2 mm first layer, the first cut is at 0.1 mm; the second layer spans 0.2 to 0.4 mm and is cut at 0.3 mm, and so on. Cutting at mid-height means each printed layer follows the cross-section halfway through the slab it replaces, which keeps slopes and domes from growing or shrinking by half a layer. A layer is only produced while its cutting plane is still below the top of the model.

Every triangle that crosses a plane contributes one short segment to that layer's outline. The important detail is how those segments are joined into closed loops. Two neighbouring triangles share an edge, and where the plane crosses that shared edge both triangles must produce exactly the same point. Here each crossing point is identified by the mesh edge it lies on and computed once, so the loops are chained by that edge rather than by searching for points that happen to be close together. This is also why a watertight mesh matters: if the surface has a hole, some edge has a triangle on only one side, the chain has nowhere to go and the loop stays open. Small gaps (up to two line widths) are closed by joining the open ends; larger ones are dropped and the tool warns you which layers were affected. If you see that warning, run the file through the STL printability checker to find the hole.

Finally the loops of each layer are combined by their direction. Each loop keeps the direction given by the surface it came from, with the material always on the same side, so an outer boundary runs one way and a hole runs the other. The layer's solid area is every point that the loops wind around at least once. That is why two bodies that overlap, or a shell that was accidentally duplicated, merge into one solid outline instead of cancelling each other out, while a real hole stays empty.

2. Walls: offsetting the outline inwards

A printed line has a width, normally the nozzle diameter. If the nozzle followed the outline exactly, half of every line would stick out beyond the model and the part would come out one line width too big. So the outer wall runs along the outline shifted inwards by half a line width, which puts its outside edge exactly on the model's surface. Each inner wall is shifted a further full line width inwards. With the default two walls and a 0.4 mm line, the wall centrelines sit 0.2 mm and 0.6 mm inside the surface, and whatever is left more than 0.8 mm inside is handed on to the skin and infill stage. If a feature is so thin that not even the outer wall fits, the tool warns you instead of silently printing nothing there.

Offsetting a polygon sounds trivial but is the hardest part of any slicer: corners have to be joined, and when a shape shrinks, parts of it can collide, split into two or vanish. This engine has its own offset routine that shifts every edge, joins the corners and then keeps only the area that is genuinely inside, so a narrow waist in a part correctly splits into two separate wall loops.

3. Top and bottom skins

The inside of a part is normally printed sparsely, but the surfaces you see and touch must be solid. The question for each point of a layer is: is this close to a top or bottom surface? The answer here is decided line by line. The area inside the walls is scanned with parallel lines, and for each line the tool checks the outlines of the N layers above and the N layers below (N is your "top layers" and "bottom layers" setting, 3 by default). Any stretch of the line that is covered by all of those layers is buried deep inside the part and gets sparse infill. Any stretch that is not covered, because the model ends within N layers above or below that spot, becomes skin: solid lines spaced one line width apart. Because the check is done per stretch of line rather than per layer, a stepped part gets a solid roof exactly over each step, not on the whole layer. Skin lines alternate between 45° and 135° from one layer to the next so each layer bridges across the one below.

4. Infill and how density becomes spacing

Sparse infill uses the same scanlines with a wider spacing. For the lines pattern, the spacing is the line width divided by the density: 20 % with a 0.4 mm line gives a line every 2 mm, in one direction per layer, alternating like the skin. For the grid pattern, each layer prints both directions, so each direction is spaced twice as far apart (2 × 0.4 ÷ 0.2 = 4 mm) to keep the same amount of plastic. At 100 % infill the lines simply become solid. Scanlines are placed on a fixed grid, so layers printed at the same angle put their infill lines exactly on top of each other.

5. Putting the paths in order

Within each layer the order is fixed: the skirt (a loop around the part on the first layer, to prime the nozzle), then the walls from the innermost to the outer one, then the skin, then the infill. Printing the outer wall last lets it lean on the walls already laid inside it, which gives a cleaner surface; this is also the default of the popular desktop slicers. Inside each group the nozzle always goes to the nearest remaining path, and each loop starts at the point closest to where the nozzle already is, to keep travel short. Before a long travel move the filament is retracted so it does not ooze across the part.

6. How much plastic each line needs

For every extruding move, the volume of the line is its width × layer height × length. The printer is told how much filament to feed, so that volume is divided by the cross-section of the filament (π × (1.75 ÷ 2)² ≈ 2.405 mm² for 1.75 mm filament). A 10 mm line 0.4 mm wide and 0.2 mm high is 0.8 mm³, which is about 0.33 mm of filament. The G-code uses relative extrusion (the M83 command), so each move carries the amount for that move alone rather than a running total. The printer's own start sequence, copied from the Cura definition of your machine, runs first in absolute mode, and the tool switches to relative mode right after it.

Walls, skin and skirt are printed at half the print speed and infill at full speed; the whole first layer uses the slower first-layer speed. The time estimate walks the same list of moves that is written to the file and assumes each move accelerates and decelerates at your printer's acceleration setting, which is why it is an estimate and not a guarantee.

When not to use this tool

This is a focused slicer for single, self-supporting parts on Marlin printers. It does not generate supports, so overhangs steeper than your printer can bridge will droop. It has no brim or raft, only a skirt. It slices one model at a time rather than a plate of several different parts, and it writes G-code for Marlin firmware only. If you need any of those, use a full desktop slicer such as Ultimaker Cura or PrusaSlicer. The STL printability checker is still worth running before either one.

This online slicerDesktop slicers (Cura, PrusaSlicer)
InstallationNone, opens in a browser tabDownload, install and keep updated
Where the model is processedOn your device, never uploadedOn your device
Supports, brim, raftNot availableAvailable
Several parts on one plateOne model at a timeYes
FirmwareMarlinMarlin, RepRap/RepRapFirmware and others; Klipper via printer profiles
Best forQuick, simple parts on any computerComplex parts and fine-tuning

After slicing, the cost panel under the summary prices the print from its grams and time with your own filament, electricity and hourly rates; if you already know those figures from another slicer, the 3D print cost calculator does the same sum without a model.

Want to print a picture rather than a model? Depth Map to STL turns an image or a depth map into a flat-backed relief that you can slice here.

For a logo, a drawing or a silhouette, Image to STL traces the shape into a flat part, a keychain or a plate with a raised drawing, and hands it to this slicer with one click.

Already have a G-code file, from this slicer or another one? Open it in the online G-code viewer to check its layers, time and filament before printing.

Frequently Asked Questions

Does this slicer upload my model?

No. The file is read and sliced inside your browser, in a background worker on your own device, and the G-code is created there too. Nothing is sent to a server, so it is safe for designs under NDA or parts you have not published yet.

Which printers does it support?

It has presets for the Artillery Sidewinder X1 (the default), the Creality Ender-3 and Ender-3 v2, the Creality Ender-3 V3 SE and the Prusa i3 MK3/MK3S, plus a generic Marlin profile. Any printer running Marlin firmware with a 1.75 mm filament and a 0.4 mm nozzle can use the generic profile or the closest preset, as long as the model fits its bed.

Can I use it with Klipper?

Not for now. The output is Marlin G-code and the start and end sequences come from each printer's Marlin profile. Many Klipper setups expect their own start macro instead, which this tool does not generate. For a Klipper printer, use a desktop slicer with a Klipper profile.

Why are there no supports?

Generating good supports is a large problem of its own (where they are needed, how they touch the part, how easily they break away), and a poor support is worse than none. This first version prints self-supporting models only. Orient your part so overhangs stay under about 45°, or use Cura or PrusaSlicer for models that need support.

How accurate is the print time estimate?

It is a close estimate, not an exact figure. Every move in the file is timed with your printer's acceleration and jerk from its Cura profile, speeding up and slowing down on each line. Real firmware also blends consecutive moves together and heats up for a variable time before printing, so the actual print can differ by a noticeable margin on models with many short curved moves.

What if my STL has holes?

Small gaps of up to two line widths are closed automatically. Larger ones leave an open outline that cannot be filled; that part of the layer is left out and you get a warning listing the affected layers. Open the file in the <a href="/en/3d-printing/stl-printability-checker/">STL printability checker</a> to see exactly where the hole is, fix it in your modelling program and slice again.

Which file formats can I load?

Binary and ASCII STL, Wavefront OBJ and 3MF. STL and OBJ files carry no units, so they are read as millimetres, which is what almost every exporter uses. A 3MF file declares its unit, and you get a warning if it is not millimetres. The result is a plain .gcode text file.

Can it tell me what the print will cost?

Yes. Under the summary, the Print cost panel multiplies the sliced grams and print time by your rates: filament price per kg, electricity price per kWh, printer power, and optionally a machine rate, setup fee, margin and minimum price. Changing a rate updates the price instantly without slicing again, and your rates are remembered in this browser. The standalone <a href="/en/3d-printing/3d-print-cost-calculator/">3D print cost calculator</a> uses the same formula and rates.

Is the G-code safe to run on my printer?

For the named printers (Artillery Sidewinder X1, Creality Ender-3, Ender-3 V3 SE, Prusa i3 MK3) the start and end G-code is copied from Ultimaker Cura's public definition of that printer, and the tool checks that the model fits the bed before slicing. The generic Marlin profile is a conservative fallback: its start sequence only homes the axes and resets the extruder, its end sequence turns off the heaters and motors, and its bed is assumed to be 220 × 220 mm, so replace those with your machine's own values if you use it. Even so, review the start sequence for your own machine (especially if you have changed its firmware or hardware), check the first layer in the preview, and stay near the printer for the first few minutes, as you would with any slicer.

Learn more