In this categoryDify · 9
DifyBeginner

How to Get Started with Dify AI Platform

Install Dify locally with Docker, connect your first LLM provider, and have a working chatbot running in under fifteen minutes.

12 minBeginner

Dify is an open-source platform for building LLM-powered apps without writing orchestration code from scratch. You connect a model provider, add knowledge bases or tools, and get a chatbot, workflow, or agent in minutes. This guide covers the fastest path from zero to a working Dify install with a live chatbot.

What you need

  • Docker Desktop (any recent version)
  • An API key from OpenAI, Anthropic, or any supported provider
  • 4 GB RAM free
  • About 15 minutes

Step 1: Clone and start Dify

Dify ships a Docker Compose file that starts every service — the API server, worker, web frontend, and databases — with one command. Clone the repo and bring it up.

bash
$git clone https://github.com/langgenius/dify.git
$cd dify/docker
$cp .env.example .env
$docker compose up -d
Starting dify-web ... done
Starting dify-api ... done
First pull takes 2-3 minutes to download images
$

Step 2: Open the setup wizard

Navigate to http://localhost and the Dify setup wizard opens automatically. Create your admin account, then skip the invite step — you can add team members later.

First login
The default URL is http://localhost (port 80). If port 80 is already in use, edit the NGINX_PORT variable in your .env file before running docker compose up.

Step 3: Add a model provider

Go to Settings > Model Provider and paste your API key. Dify supports Claude, GPT-4o, Gemini, Mistral, local Ollama models, and dozens more. Select a default chat model from the dropdown — this is what new apps use unless you override it.

Step 4: Create your first chatbot

Click New App, pick Chatbot, give it a name, and click Create. In the prompt editor, write a system prompt describing what the assistant should do. Hit Publish, then open the Share link to test it in a browser. That is a live chatbot backed by your model.

Next steps
From here you can add a knowledge base for RAG, enable tools like web search or code execution, or switch from Chatbot to Agent mode for multi-step tasks. Each is a single toggle in the same interface.

Related guides

Watch related tutorials

Free weekly email

New guides in your inbox

Fresh step-by-step how-to guides as we publish them. One email a week, no more.

Tags
#dify#dify ai#dify tutorial#llm#setup#docker