DEV Community

keeper
keeper

Posted on

3D Print Stringing: Causes, Fixes, and How to Detect It Automatically

If you've been 3D printing for more than a few hours, you've seen it: thin, wispy strands of plastic stretching between parts of your print like spiderwebs. That's stringing — and it's one of the most common quality issues in FDM printing.

In this guide, I'll walk through:

  • What causes stringing (and it's not always what you think)
  • How to fix it manually (temperature, retraction, travel settings)
  • How to automatically detect it using computer vision

Let's start with the why, then the how, then the tools.


What Actually Causes Stringing?

Stringing happens when molten plastic oozes from the nozzle during travel moves — when the nozzle moves from one part of the print to another without extruding.

Without stringing:  ╔══════╗     ╔══════╗
                    ║      ║     ║      ║
                    ╚══════╝     ╚══════╝

With stringing:     ╔══════╗~~~~~╔══════╗
                    ║      ║     ║      ║
                    ╚══════╝     ╚══════╝
                    (thin wisps between parts)
Enter fullscreen mode Exit fullscreen mode

Three factors determine whether stringing occurs:

Factor How it causes stringing
Temperature too high More molten = more ooze. Each filament has a sweet spot.
Retraction too low The nozzle doesn't pull filament back enough during travel.
Travel speed too slow Slow moves = more time for ooze to accumulate.

But the tricky part? These factors interact. Higher temperature needs more retraction. Faster travel needs different retraction settings. Changing filament brand? Start over.


Manual Fix: Step by Step

1. Lower Nozzle Temperature (First Try)

Each filament type has a range. For PLA, that's typically 190–220°C.

# Pseudocode for temperature tuning
start_temp = 220  # upper end of filament spec
end_temp = 190    # lower end
step = 5          # degrees per test

for temp in range(start_temp, end_temp - 1, -step):
    print(f"Print temperature tower slice at {temp}°C")
    # The cleanest layer = right temperature
Enter fullscreen mode Exit fullscreen mode

Print a temperature tower (available on Printables or MakerWorld). The section with the least stringing tells you your ideal temp.

2. Increase Retraction Distance

Retraction pulls filament back into the nozzle during travel. More retraction = less ooze.

Filament Type Typical Retraction (Bowden) Typical Retraction (Direct Drive)
PLA 4–7mm 0.5–1.5mm
PETG 3–5mm 0.5–1.5mm
TPU 1–3mm 0.3–1mm

3. Increase Travel Speed

Faster travel = less time for ooze. Try 150–200mm/s for travel moves.

4. Enable "Wipe" and "Avoid Printed Parts"

Most slicers have these options:

  • Wipe: Nozzle wipes against the print wall before moving, removing excess
  • Avoid printed parts: Travel paths stay away from already-printed areas

The Problem with Manual Tuning

Here's what nobody tells you about manual tuning:

You can't see the problem while the print is running. You have to finish the print, look at it, guess what's wrong, change a setting, and try again. Each iteration takes 30–60 minutes.

A 2025 analysis of r/FixMyPrint shows:

  • 1,951 posts about first layer adhesion (the #1 problem)
  • Stringing and surface quality issues are in the top 5
  • Most posts get guesses, not diagnoses

This is exactly why I built Printsight.


Automated Stringing Detection with Printsight

Printsight is an open-source CLI tool that detects stringing, layer quality issues, and warping from a single photo. No ML, no GPU, no training data — pure OpenCV computer vision.

How It Works (The Algorithm)

Stringing detection uses a dual approach:

Method 1 — Edge Detection:

  1. Canny edge detection finds all edges in the photo
  2. Hough Line Transform finds thin, non-horizontal line segments
  3. Stringing = thin lines that aren't layer boundaries

Method 2 — Morphology:

  1. Adaptive threshold separates the print from background
  2. Morphological erosion removes thin features
  3. Subtract eroded from original — only thin features remain

Results from both methods are combined for robust detection.

Installation

pip install https://github.com/bossman-lab/printsight/releases/download/v0.1.0/printsight-0.1.0-py3-none-any.whl
Enter fullscreen mode Exit fullscreen mode

Usage

# Take a photo of your print and run:
printsight my_print.jpg

# Output:
# ==================================================
#   🖨️  Printsight v0.1.0 — Quality Report
# ==================================================
#   Overall: 🟡 Fair  (score: 0.62)
#   Image:   my_print.jpg
#   
#   🟡  Stringing
#        Score:    0.51
#        Strands:  14
#
#   🟢  Layer Quality
#        Score:    0.88
#
#   🟢  Warping
#        Score:    0.95
Enter fullscreen mode Exit fullscreen mode

The stringing sub-score tells you exactly how bad the problem is:

  • 0.90+: No stringing, excellent
  • 0.75–0.89: Minor, barely visible
  • 0.50–0.74: Noticeable — needs tuning
  • <0.50: Severe — action required

From Detection to Fix

Once you know you have stringing (and how bad), Printsight's JSON output gives you the raw data:

printsight my_print.jpg --json
# → {"stringing": {"score": 0.51, "details": {"count": 14, ...}}}
Enter fullscreen mode Exit fullscreen mode

Use this data to:

  1. Track improvements — after each tuning attempt, take another photo
  2. Compare filaments — same model, different brands → which strings less?
  3. Automate quality checks — exit code 0/1 for good/bad prints

Complete Workflow: From Detection to 0 Stringing

1. Print model
   ↓
2. Take photo → run printsight → score: 0.51 (stringing!)
   ↓
3. Lower temp by 5°C
   ↓
4. Reprint → take photo → run printsight → score: 0.68
   ↓
5. Increase retraction by 0.5mm
   ↓
6. Reprint → take photo → run printsight → score: 0.91 ✅
Enter fullscreen mode Exit fullscreen mode

Each iteration takes seconds (the analysis), not 30 minutes of visual inspection.


Prevention: Better Settings From the Start

The best fix is to never have stringing in the first place. That's where FilamentDB comes in — it's a companion tool that stores optimized print settings for 25+ filament models across 7 major brands.

# Look up recommended settings for any filament
filamentdb recommend --brand "Bambu Lab" --model "PLA Basic"
# → Nozzle: 225°C, Bed: 60°C, Retraction: 0.8mm, Speed: 21mm³/s
Enter fullscreen mode Exit fullscreen mode

Summary

Method Time per Iteration Accuracy Best For
Visual inspection 30–60 min Subjective Quick checks
Temperature tower 2–3 hours Good Initial setup
Printsight 2 seconds Quantitative Iterative tuning

TL;DR: Lower temperature first, then increase retraction. Use Printsight to quantify the improvement after each change instead of guessing.


Tools mentioned in this guide:

All tools are MIT-licensed, pure Python, and require no GPU or ML training data.

Top comments (0)