YOLOv8
Use the YOLOv8 model family through our Serverless Cloud API
YOLOv8 is an object detection, instance segmentation, and keypoint detection model family from Ultralytics. Roboflow serves COCO-pretrained YOLOv8 checkpoints under short aliases, and you can upload your own weights to run a model you trained elsewhere.
Training YOLOv8 is not supported on Roboflow. For a Roboflow-trained detector, see RF-DETR, YOLO26, or YOLO11.
YOLOv8 pretrained aliases
Pass one of these IDs as model_id to run a COCO-pretrained checkpoint without training anything. The full list lives on the Pretrained Model Aliases page.
YOLOv8 API
Get your API Key
Create a Roboflow account, find your key on the Roboflow API settings page and make it available to your shell:
Install the dependencies
Install the Inference SDK and supervision for decoding and drawing predictions:
Run the model
This example runs the pretrained yolov8n-640 checkpoint. To serve your own weights, swap in your {workspace}/{model-slug} ID (see Versions, Trainings, and Models).
You can also load the checkpoint in-process with the inference package:
Upload Custom Weights
To run a YOLOv8 model you trained outside Roboflow, upload its weights to a Project with the Roboflow CLI:
Set -t to your model's size and task (ex: yolov8s-seg, yolov8m-pose). See Upload Custom Weights for the Python SDK and training version requirements.
License
YOLOv8 is released under AGPL-3.0. What that means for commercial use:
On Roboflow cloud: a commercial license is included for every user, including the free plan.
Self-hosted: you need the Enterprise license add-on, or you must open-source your application under AGPL-3.0.
Permissive alternative: RF-DETR is Apache 2.0, free for commercial use anywhere.
See Roboflow's Ultralytics licensing for details.
Last updated
Was this helpful?