For the complete documentation index, see llms.txt. This page is also available as Markdown.

Upload Images, Videos, and Annotations

Upload images, videos, and annotations to Roboflow.

The first step to training and deploying a model with Roboflow is to upload data to a Project.

First, you will need to create a Project.

Then, you will be taken to a web page from which you can upload data. You can also access this page from the "Upload Data" button available in your project sidebar.

How to Add Data

You can add data to your Roboflow account by:

  • Using the web application: Recommended for datasets with fewer than 1,000 images.

  • Using the command line: Recommended for datasets with greater than 1,000 images.

  • Using the Dataset Upload Workflow Block: Recommended for collecting data from Workflows with a model already in production.

If your images already live in cloud storage such as AWS S3, Google Cloud Storage, or Azure Blob Storage, use Datasources and Bucket Mirror as the default path instead of scripting an upload. A Datasource imports, ingests, and syncs images and metadata into your workspace automatically. Use signed URL uploads or local downloads only for one-time or ad hoc imports.

From the web application and command line, you can upload:

  • JPG, PNG, WEBP, AVIF, BMP, and HEIC/HEIF images.*

  • MOV and MP4 videos.

  • PDF files.

  • Annotations in any of the 40+ supported formats. The formats you can use depend on your Project type.

*Max size of 30 MB, 16,384 pixels per side, and 178,956,970 pixels (about 179 megapixels) in total.

You can only upload annotations with their associated images. You cannot upload annotations for images that have already been imported into your dataset.

How file names are processed

Roboflow standardizes class names at upload, import, and export:

  • Leading and trailing whitespace is trimmed.

  • All whitespace (including newlines and tabs) becomes a space.

  • Double spaces are removed.

  • /.[]#~* characters are replaced with a dash (-).

  • |'" characters are removed.

Web App

Drag and drop images, videos, and annotations onto the Upload Data page, or onto the upload box you see when you create a Project.

Capture From a Camera

To add images or video from a webcam or a phone used as a webcam, click "Use Camera" on the Upload Data page and pick a camera. Use "Photo" to take one image at a time, "Interval" to capture 1 frame every 0.2 to 60 seconds (up to 1,000 images), or "Video" to record an MP4 clip up to 300 seconds. After you record a clip, click "Keep Video". Then click the add button (ex: "Add 12 to Upload", "Add Video to Upload") to add the captures to your upload. In image-based Projects, a clip then opens the extraction dialog. Video mode is not available in browsers that cannot record MP4 (ex: Firefox).

Upload a Zip File

A .zip archive of up to 300 files extracts in your browser and goes through the same flow as a dropped folder, keeping any nested folders. A larger archive (up to 8 GB) uploads as one file and is processed on Roboflow's servers. Once the upload bar finishes, you can keep working and follow progress in your Activity Center. The images appear in a batch on your Annotate page. For archives over 8 GB, use the CLI.

By default, images already in the Project keep their annotations. To replace them with the ones in the zip, check "Replace annotations on images already in this project" in the confirmation dialog. Classification Projects always replace the label.

If the archive includes annotations, its images land in a new annotation job credited to you, even when you upload the same zip again. With Review Mode on, they wait in Review until a reviewer approves them. With it off, they join your dataset right away.

Upload Video

Image-based Projects split each video into frames you annotate. Action Recognition Projects keep each video intact so you can label actions as video segments.

The extraction dialog samples frames at an interval from 60 frames per second down to 1 frame every 60 seconds. Drag the trim handles on the filmstrip to exclude frames outside a range. To pick frames by hand, click "Manual selection", then press M to add the current frame, , and . to step one frame, and Shift+Left and Shift+Right to jump between selected frames. Sampled and selected frames are merged without duplicates.

When you queue several videos, you can apply the same interval to all of them. Selected frames belong to one video, so each video with selected frames opens its own dialog.

Supported video file formats

Roboflow decodes videos with your browser, so the formats you can upload depend on your browser's video support. MOV and MP4 work in most browsers.

If your browser can't decode a video, Roboflow shows an "unsupported video" error. HEVC/H.265 is a common cause (ex: footage from DJI drones, GoPros, and newer phones) and only Safari decodes it. Convert the video to MP4 (H.264) and upload it again.

If a video still won't load, post on the forum or contact your account representative.

Import Video Segment Annotations

Action Recognition projects can import labels that say when each action happens. Drag in a folder of videos with one _annotations.coco.json beside each video it describes:

Each file sets info.format to roboflow-video-coco and describes one MP4 or MOV video. Spatial and per-frame annotations are skipped, and zip archives are not accepted. A folder named train, valid, or test sets the split of the videos inside it. Otherwise you pick the split before the upload starts.

Importing a video again replaces its segments, unless it already has frame annotations, which Roboflow keeps instead.

HTTP API

Upload a Video

Upload MP4 or MOV videos up to 3 GB to your Workspace, or to a Project such as an Action Recognition Project. An upload takes three steps:

  1. Prepare the upload. You get a videoId, a signedUrl, and requiredHeaders.

  2. Send the video file with a PUT request to signedUrl, with every header in requiredHeaders. The URL expires after 60 minutes.

  3. Read the upload status until status is uploaded or failed.

The optional batch, tag, metadata, and split fields work like they do for image uploads. If the same video is already in the Project, Roboflow reuses it. The video keeps its batch and gets your tags, metadata, and split.

Prepare a video upload

post

Creates a pending video and returns a signed URL for its file. The video joins the workspace, and the project when you set one, after you PUT the file to signedUrl and Roboflow processes it.

Authorizations
AuthorizationstringRequired

Roboflow API key or OAuth access token.

Path parameters
workspacestringRequired

Workspace URL slug.

Body
namestring · min: 1 · max: 1024Required

File name of the video.

contentTypestring · enumRequired

MIME type of the video file.

Possible values:
projectstringOptional

Project URL slug. Omit it to add the video to the workspace only. API keys scoped to project folders must set it.

batchstring · min: 1 · max: 1024Optional

Batch name. Requires project. Without it, the video gets a batch of its own.

tagone ofOptional

One tag or a list of tags to add to the video.

string · min: 1Optional
or
string[]Optional
splitstring · enumOptional

Split the video goes to when you generate a version. Requires project. Defaults to train when you set project. The aliases val and validation map to valid.

Possible values:
Responses
200

Successful response.

application/json
videoIdstringRequired

ID of the new video. Use it to read the upload status.

signedUrlstring · uriRequired

URL to PUT the video file to. It expires after 60 minutes.

post/{workspace}/upload/video
POST /{workspace}/upload/video HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 174

{
  "name": "dock-cam.mp4",
  "contentType": "video/mp4",
  "project": "warehouse-actions",
  "batch": "Warehouse cams",
  "tag": [
    "dock",
    "night"
  ],
  "metadata": {
    "camera": "dock-1"
  },
  "split": "valid"
}
{
  "videoId": "abc123",
  "signedUrl": "https://storage.googleapis.com/...",
  "requiredHeaders": {
    "x-goog-content-length-range": "1,3221225472",
    "x-goog-if-generation-match": "0"
  }
}

Get video upload status

get

Reads the processing status of a video upload.

Authorizations
AuthorizationstringRequired

Roboflow API key or OAuth access token.

Path parameters
workspacestringRequired

Workspace URL slug.

videoIdstringRequired

Video ID returned when you prepared the upload.

Responses
200

Successful response.

application/json
videoIdstringRequired

ID of the video. When duplicate is true, this is the ID of the video that was already in the workspace.

statusstring · enumRequired

pending while Roboflow processes the video, then uploaded or failed.

Possible values:
duplicatebooleanOptional

True when the same video was already in the workspace, so Roboflow reused it.

messagestringOptional

Why the upload failed. Present when status is failed.

get/{workspace}/upload/video/{videoId}
GET /{workspace}/upload/video/{videoId} HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "videoId": "abc123",
  "status": "uploaded",
  "resolvedBatch": {
    "id": "def456",
    "name": "Warehouse cams"
  }
}

To find uploaded videos, search the dataset with mediaTypes set to ["video"].

CLI

You can upload larger datasets using the Roboflow Python command line interface.

You can only upload images with the command line interface. If you have videos, you will need to split them into frames saved as files. These files can then be uploaded to Roboflow.

To get started, first install roboflow-python:

Next, retrieve your Workspace ID.

Finally, prepare a command in the following format:

Here are the arguments you need to specify:

  • -w testupload: This is the workspace name.

  • -p <project-id>: This is your project ID.

When you run the command, you will see a message that indicates the upload process has started. You will then see logs as images upload:

Uploading a dataset using the command-line

We have a video walkthrough that shows how to upload data from the command line:

Upload a Zip File

For large datasets, you can upload a single .zip archive of your images and annotations instead of individual files. The archive is uploaded once and processed asynchronously on Roboflow's servers, which is faster and more reliable than uploading file by file.

Upload a .zip directly:

Or let the CLI zip a folder for you before uploading:

By default the command waits for processing to finish and prints a summary. Pass --no-wait to return immediately; the CLI prints a task ID you can use to poll the upload status.

Python SDK

Use Workspace.upload_dataset() to upload a .zip archive or zip a folder before upload:

Zip upload supports archives up to 8 GB and 100,000 files. Predictions (is_prediction=True) are not supported on the zip path - use the per-image upload for those.

MCP Server

Connect your AI agent to the MCP Server and it can add images to a project with these tools:

Tool
Description

image_upload

Upload local image files to a project via a zip.

image_upload_status

Check the status of an image zip upload task.

images_update_metadata

Update metadata and tags on an uploaded image.

View Your Uploaded Data

All data uploaded to Roboflow is uploaded in a "batch". These batches can be viewed on your Project Annotate page:

Image Size limits

An image can be at most 30 MB, at most 16,384 pixels on each side, and at most 178,956,970 pixels (about 179 megapixels) in total. Every upload method refuses a larger image, including the web app, the API, zip uploads, and Datasources. Images uploaded before these limits stay in your Project.

Duplicate Images

If you try to upload an image that is already in a Project, upload for that image will be skipped.

Removing an image from a Project keeps its annotations. If you upload that image again, it rejoins the Project with those annotations and its old annotation status, so an annotated image does not come back as unannotated.

If you merge two datasets, the merged dataset and the two original datasets exist in your account. Therefore, there is no charge for the merge, because the images are duplicates.

Data Ownership

You retain ownership over all images and videos you upload to Roboflow. This is defined in our Section 23B of our Terms of Service:

You retain all ownership rights in any content, information, or materials You post, submit, publish, display, or transmit

Data Privacy

Private projects are not publicly listed on Roboflow Universe. You can control project privacy.

Last updated

Was this helpful?