Overview
Flowise is an open-source low-code tool for building LLM applications through a visual drag-and-drop interface. Built on top of LangChain and LlamaIndex, it enables rapid prototyping of chatbots, RAG systems, and multi-agent workflows without writing extensive code. Flowise supports dozens of LLM providers, vector stores, document loaders, and tools through its modular node system.
The platform is designed for developers and non-developers alike who want to experiment with and deploy AI pipelines quickly. It provides a marketplace of pre-built templates, built-in credential management, conversation memory, and REST API endpoints for every chatflow. Flowise can be self-hosted or deployed to cloud platforms with Docker.
Installation
NPM (Quick Start)
npm install -g flowise
npx flowise start
# Access UI at http://localhost:3000
Docker
docker run -d \
--name flowise \
-p 3000:3000 \
-v flowise_data:/root/.flowise \
flowiseai/flowise
# With environment variables
docker run -d \
--name flowise \
-p 3000:3000 \
-e FLOWISE_USERNAME=admin \
-e FLOWISE_PASSWORD=securepassword \
-e APIKEY_PATH=/root/.flowise \
-e DATABASE_PATH=/root/.flowise \
-v flowise_data:/root/.flowise \
flowiseai/flowise
Docker Compose
version: '3.8'
services:
flowise:
image: flowiseai/flowise
restart: always
ports:
- "3000:3000"
environment:
- FLOWISE_USERNAME=admin
- FLOWISE_PASSWORD=securepassword
- DATABASE_TYPE=postgres
- DATABASE_HOST=postgres
- DATABASE_PORT=5432
- DATABASE_USER=flowise
- DATABASE_PASSWORD=flowise
- DATABASE_NAME=flowise
volumes:
- flowise_data:/root/.flowise
depends_on:
- postgres
postgres:
image: postgres:16
restart: always
environment:
- POSTGRES_USER=flowise
- POSTGRES_PASSWORD=flowise
- POSTGRES_DB=flowise
volumes:
- pgdata:/var/lib/postgresql/data
volumes:
flowise_data:
pgdata:
From Source
git clone https://github.com/FlowiseAI/Flowise.git
cd Flowise
pnpm install
pnpm build
pnpm start
Core Concepts
Node Categories
| Category | Examples | Purpose |
|---|
| LLMs | ChatOpenAI, ChatAnthropic, Ollama | Language model providers |
| Embeddings | OpenAI Embeddings, HuggingFace | Text vectorization |
| Vector Stores | Pinecone, Chroma, Qdrant, FAISS | Store and retrieve vectors |
| Document Loaders | PDF, CSV, Web, Notion, Confluence | Ingest documents |
| Text Splitters | Recursive, Token, Markdown | Chunk documents |
| Memory | Buffer, Window, Summary, Redis | Conversation history |
| Chains | Conversational, RetrievalQA, LLM | Processing pipelines |
| Agents | OpenAI Functions, ReAct, Plan-Execute | Autonomous tool use |
| Tools | Calculator, SerpAPI, Custom API | Agent capabilities |
API Usage
# Send a prediction (chat message)
curl -X POST http://localhost:3000/api/v1/prediction/{chatflowId} \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"question": "What is machine learning?",
"overrideConfig": {
"temperature": 0.7
}
}'
# Send with conversation history
curl -X POST http://localhost:3000/api/v1/prediction/{chatflowId} \
-H "Content-Type: application/json" \
-d '{
"question": "Tell me more about that",
"chatId": "existing-chat-id",
"history": [
{"role": "user", "content": "What is ML?"},
{"role": "assistant", "content": "ML is..."}
]
}'
# Upload file for processing
curl -X POST http://localhost:3000/api/v1/prediction/{chatflowId} \
-H "Authorization: Bearer YOUR_API_KEY" \
-F 'files=@document.pdf' \
-F 'question=Summarize this document'
# Upsert documents to vector store
curl -X POST http://localhost:3000/api/v1/vector/upsert/{chatflowId} \
-H "Content-Type: application/json" \
-d '{
"overrideConfig": {
"pineconeIndex": "my-index"
},
"stopNodeId": "vectorStore_0"
}'
# List chatflows
curl -X GET http://localhost:3000/api/v1/chatflows \
-H "Authorization: Bearer YOUR_API_KEY"
Building a RAG Pipeline
Step-by-Step Flow
- Document Loader — Add a PDF Loader or Text File node
- Text Splitter — Connect a Recursive Character Text Splitter
- Embedding — Add OpenAI Embeddings or HuggingFace
- Vector Store — Connect to Pinecone, Chroma, or FAISS
- Retriever — Configure top-k and similarity threshold
- LLM — Add ChatOpenAI or ChatAnthropic
- Chain — Use Conversational Retrieval QA Chain
Override Configuration
{
"question": "Explain the architecture",
"overrideConfig": {
"model": "gpt-4",
"temperature": 0.3,
"maxTokens": 2000,
"topK": 5,
"systemMessage": "You are a technical documentation assistant."
}
}
Configuration
Environment Variables
| Variable | Description | Default |
|---|
FLOWISE_USERNAME | Login username | None |
FLOWISE_PASSWORD | Login password | None |
PORT | Server port | 3000 |
DATABASE_TYPE | sqlite or postgres or mysql | sqlite |
DATABASE_PATH | SQLite database path | ~/.flowise |
APIKEY_PATH | API keys storage path | ~/.flowise |
LOG_LEVEL | error, info, verbose, debug | info |
TOOL_FUNCTION_BUILTIN_DEP | Allowed npm packages in custom tools | None |
TOOL_FUNCTION_EXTERNAL_DEP | External npm packages whitelist | None |
CORS_ORIGINS | Allowed CORS origins | * |
IFRAME_ORIGINS | Allowed iframe origins | None |
Credential Management
# Credentials are stored encrypted in the database
# Set encryption key via environment variable
SECRETKEY_OVERWRITE=your-256-bit-secret-key
# Supported credential types:
# - OpenAI API Key
# - Anthropic API Key
# - Pinecone API Key
# - HuggingFace Access Token
# - AWS credentials
# - Google Cloud credentials
# - Custom API keys
Advanced Usage
// Custom JavaScript tool node
// Available: $input, $vars, $flow
const fetch = require('node-fetch');
const response = await fetch('https://api.example.com/data', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${$vars.apiKey}`
},
body: JSON.stringify({ query: $input })
});
const data = await response.json();
return JSON.stringify(data);
<!-- Fullpage chatbot -->
<script type="module">
import Chatbot from 'https://cdn.jsdelivr.net/npm/flowise-embed/dist/web.js';
Chatbot.initFull({
chatflowid: 'your-chatflow-id',
apiHost: 'http://localhost:3000',
theme: {
button: { backgroundColor: '#3B81F6' },
chatWindow: {
welcomeMessage: 'Hello! How can I help?',
backgroundColor: '#ffffff',
fontSize: 16
}
}
});
</script>
<!-- Bubble chatbot -->
<script type="module">
import Chatbot from 'https://cdn.jsdelivr.net/npm/flowise-embed/dist/web.js';
Chatbot.init({
chatflowid: 'your-chatflow-id',
apiHost: 'http://localhost:3000',
chatflowConfig: {
topK: 3,
temperature: 0.5
}
});
</script>
Multi-Agent Setup
Flow structure:
Supervisor Agent
├── Research Agent (SerpAPI tool)
├── Writer Agent (LLM + prompt)
└── Code Agent (Code interpreter tool)
Each agent node:
- Has its own system prompt
- Can use specific tools
- Reports back to supervisor
- Supervisor decides next step
Streaming Responses
// Server-Sent Events streaming
const response = await fetch(
'http://localhost:3000/api/v1/prediction/chatflow-id',
{
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
question: 'Explain quantum computing',
streaming: true
})
}
);
const reader = response.body.getReader();
const decoder = new TextDecoder();
while (true) {
const { done, value } = await reader.read();
if (done) break;
const chunk = decoder.decode(value);
process.stdout.write(chunk);
}
Troubleshooting
| Issue | Solution |
|---|
| Port 3000 already in use | Set PORT=3001 environment variable |
| Cannot connect to LLM | Check API key in Credentials, verify model name |
| Vector store upsert fails | Ensure embeddings dimension matches vector store config |
| Memory overflow with large docs | Use smaller chunk sizes (500-1000 chars) |
| CORS errors in embed widget | Set CORS_ORIGINS to your domain |
| Custom tool npm packages fail | Add package names to TOOL_FUNCTION_EXTERNAL_DEP |
| SQLite database locked | Switch to PostgreSQL for production |
| Chatflow not responding | Check node connections, ensure all required inputs are linked |
# Debug logging
LOG_LEVEL=debug npx flowise start
# Check container logs
docker logs -f flowise
# Reset database
rm -rf ~/.flowise/database.sqlite
npx flowise start