This page is being translated by your browser

Translation can break parts of Roboflow. If something stops working, turn translation off and reload the page.

Detection · Manufacturing & QC

Surface defect detection: Datasets & Models

Automated visual inspection that locates and classifies surface defects like scratches, dents, and cracks on manufactured parts. Runs on production line cameras to flag flawed units in real time.

Surface defect detection example
1M+
developers
16k
organizations
50B
inferences

Surface defect detection

This detection workflow analyzes images of manufactured parts to locate and classify surface defects such as scratches, dents, cracks, corrosion, and stains, returning a bounding box and defect class for each finding. It accepts still images or video frames from line-scan or area-scan cameras, making it suitable for training on a surface defect dataset and running inline inspection on production lines.

Try it out

Powered by general detection model

Run on custom image

Drop an image here or click to upload

Detecting classes:

Why automate surface defect detection

Manual surface inspection is slow, subjective, and hard to scale across shifts, and human inspectors miss subtle defects when fatigued or when line speeds increase. Automating defect detection with computer vision gives every part the same consistent scrutiny, catches flaws earlier in the process, and produces an auditable record of what was found and where. For manufacturing and QC teams, this reduces scrap and warranty claims by pulling defective units before they move downstream or reach customers.

Key benefits

Detection models localize defects precisely so you can measure size, count, and location rather than just pass/fail. The workflow integrates with the machine vision cameras and PLCs already on your line, scales across multiple stations and product lines, and improves as you add more labeled examples of new defect types. RF-DETR offers strong accuracy on small, low-contrast defects while remaining practical to deploy at production frame rates.

How to use it

  1. Upload an image: Drop any photo into the widget above to try surface defect detection for free, right on this page.
  2. Preview instant results: The model detects scratch, dent, crack, corrosion, stain within seconds and returns an annotated image with structured predictions, so you can immediately see how well it works. Adjust the detection classes and re-run until the results fit your scenario.
  3. Like what you see?: With a free Roboflow account, you can deploy this workflow with the Serverless Cloud API, customize it in your workspace, or train RF-DETR on your own images for production accuracy.
  4. Get started for free: No code or training data required to begin: upload, review the results, and make it part of your stack in a single click.
Recommended model

Recommended model for surface defect detection

RF-DETR is state of the art for real-time object detection, instance segmentation, and keypoint detection, with higher accuracy and lower latency than comparable models, and it's Apache 2.0 licensed. When you're ready to build a production model for surface defect detection, fine-tune it on your own labeled images, then deploy to a Serverless Cloud API endpoint.

Train your own model
Roboflow Agent

Not sure where to start?

Describe your Surface Defect Detection project to Roboflow Agent.

Agent