const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN})const model = const input = { prompt: };const [output] = await replicate.run(model, { input });console.log(output);A poolside patio at sunset with vintage lounge chairs.
black-forest-labs/flux-2-proA soft armchair shaped like a peeled banana.
google/nano-banana-proA woman relaxing in a french bookstore.
bytedance/seedream-4A futuristic robot looking into the distance.
black-forest-labs/flux-proAn abstract painting of a sunrise.
black-forest-labs/flux-proWith Replicate you can
prunaai / p-image
A sub 1 second text-to-image model built for production use cases.
830K runs
prunaai / z-image-turbo
Z-Image Turbo is a super fast text-to-image model of 6B parameters developed by Tongyi-MAI.
7.5M runs
google / nano-banana-pro
Google's state of the art image generation and editing model 🍌🍌
8.3M runs
google / imagen-4-fast
Use this fast version of Imagen 4 when speed and cost are more important than quality
3.5M runs
black-forest-labs / flux-2-max
The highest fidelity image model from Black Forest Labs
158K runs
bytedance / seedream-4.5
Seedream 4.5: Upgraded Bytedance image model with stronger spatial understanding and world knowledge
1.4M runs
bytedance / seedream-4
Unified text-to-image generation and precise single-sentence editing at up to 4K resolution
21.7M runs
google / nano-banana
Google's latest image editing model in Gemini 2.5
69.7M runs
All the latest models are on Replicate. They’re not just demos — they all actually work and have production-ready APIs.
AI shouldn’t be locked up inside academic papers and demos. Make it real by pushing it to Replicate.
bytedance / seedance-1.5-pro
A joint audio-video model that accurately follows complex instructions.
76.4K runs
qwen / qwen-image-edit-2511
An enhanced version over Qwen-Image-Edit-2509, featuring multiple improvements including notably better consistency
87.3K runs
openai / gpt-image-1.5
OpenAI's latest image generation model with better instruction following and adherence to prompts
884.1K runs
black-forest-labs / flux-2-max
The highest fidelity image model from Black Forest Labs
158K runs
resemble-ai / chatterbox-turbo
The fastest open source TTS model without sacrificing quality.
23.7K runs
openai / gpt-5.2
The best model for coding and agentic tasks across industries
166.3K runs
bytedance / seedream-4.5
Seedream 4.5: Upgraded Bytedance image model with stronger spatial understanding and world knowledge
1.4M runs
prunaai / z-image-turbo
Z-Image Turbo is a super fast text-to-image model of 6B parameters developed by Tongyi-MAI.
7.5M runs
google / gemini-3-pro
Google's most advanced reasoning Gemini model
266.3K runs
google / nano-banana-pro
Google's state of the art image generation and editing model 🍌🍌
8.3M runs
google / veo-3.1
New and improved version of Veo 3, with higher-fidelity video, context-aware audio, reference image and last frame support
272K runs
philz1337x / crystal-upscaler
High-precision image upscaler optimized for portraits, faces and products. One of the upscale modes powered by Clarity AI. X:https://x.com/philz1337x
319.9K runs
You can get started with any model with just one line of code. But as you do more complex things, you can fine-tune models or deploy your own custom code.
Our community has already published thousands of models that are ready to use in production. You can run these with one line of code.
import replicateoutput = replicate.run( "black-forest-labs/flux-dev", input={ "aspect_ratio": "1:1", "num_outputs": 1, "output_format": "jpg", "output_quality": 80, "prompt": "An astronaut riding a rainbow unicorn, cinematic, dramatic", })print(output)You can improve models with your own data to create new models that are better suited to specific tasks.
Image models like SDXL can generate images of a particular person, object, or style.
Train a model:
training = replicate.trainings.create( destination="mattrothenberg/drone-art" version="ostris/flux-dev-lora-trainer:e440909d3512c31646ee2e0c7d6f6f4923224863a6a10c494606e79fb5844497", input={ "steps": 1000, "input_images": , "trigger_word": "TOK", },)This will result in a new model:
Fantastical images of drones on land and in the sky
0 runs
mattrothenberg / drone-art
Fantastical images of drones on land and in the sky
0 runs
Then, you can run it with one line of code:
output = replicate.run( "mattrothenberg/drone-art:abcde1234...", input={"prompt": "a photo of TOK forming a rainbow in the sky"}),)You aren’t limited to the models on Replicate: you can deploy your own custom models using Cog, our open-source tool for packaging machine learning models.
Cog takes care of generating an API server and deploying it on a big cluster in the cloud. We scale up and down to handle demand, and you only pay for the compute that you use.
First, define the environment your model runs in with cog.yaml:
build: gpu: true system_packages: - "libgl1-mesa-glx" - "libglib2.0-0" python_version: "3.10" python_packages: - "torch==1.13.1"predict: "predict.py:Predictor"Next, define how predictions are run on your model with predict.py:
from cog import BasePredictor, Input, Pathimport torchclass Predictor(BasePredictor): def setup(self): """Load the model into memory to make running multiple predictions efficient""" self.model = torch.load("./weights.pth") # The arguments and types the model takes as input def predict(self, image: Path = Input(description="Grayscale input image") ) -> Path: """Run a single prediction on the model""" processed_image = preprocess(image) output = self.model(processed_image) return postprocess(output)Thousands of businesses are building their AI products on Replicate. Your team can deploy an AI feature in a day and scale to millions of users, without having to be machine learning experts.
Learn more about our enterprise plansIf you get a ton of traffic, Replicate scales up automatically to handle the demand. If you don't get any traffic, we scale down to zero and don't charge you a thing.
Replicate only bills you for how long your code is running. You don't pay for expensive GPUs when you're not using them.
Deploying machine learning models at scale is hard. If you've tried, you know. API servers, weird dependencies, enormous model weights, CUDA, GPUs, batching.
Prediction throughput (requests per second)
Metrics let you keep an eye on how your models are performing, and logs let you zoom in on particular predictions to debug how your model is behaving.
With Replicate and tools like Next.js and Vercel, you can wake up with an idea and watch it hit the front page of Hacker News by the time you go to bed.