Skip to content
BotServBotServ
PostizSocial MediaBuffer AlternativeSelf-HostingOpen SourceContentScheduling

Postiz Self-Hosted: Social Media Scheduling with AI

Self-host Postiz: Open-source social media manager and Buffer alternative. Schedule posts, AI content generation with Ollama.

S

schutzgeist

4 min read
Postiz Self-Hosted: Social Media Scheduling with AI

Postiz self-hosted: Social media scheduling with AI

What this article covers

  • What Postiz is: Open-source social media manager (Buffer/Hootsuite alternative).
  • Docker setup and channel integration.
  • Scheduling posts, managing channels, analytics.
  • AI content generation with Ollama: draft posts automatically.
  • Automation workflows with n8n.

Introduction

Postiz is the most modern open-source alternative to Buffer and Hootsuite: a social media scheduler that plans and publishes posts to X, LinkedIn, Instagram, Facebook, TikTok, YouTube, Mastodon, Reddit, Discord, Slack, Telegram, and more from a single interface.

For AI self-hosters, Postiz offers an API and webhook support. Combining it with Ollama creates a workflow that automatically transforms content ideas into finished posts for all your channels.

Common use cases

  • Multi-channel posting: One post sent automatically across all channels (X, LinkedIn, Mastodon, Discord).
  • AI content pipeline: Ollama generates posts from blog articles, then Postiz schedules them.
  • Team workflows: Manage drafts, approvals, and scheduled posts across your team.
  • Evergreen recycling: Automatically reschedule old posts.
  • Blog to social: New article triggers n8n, which posts teasers to all channels via Postiz.

Installation: Docker

services:
  postiz:
    image: ghcr.io/gitroomhq/postiz-app:latest
    ports: ["127.0.0.1:4200:5000"]
    environment:
      - DATABASE_URL=postgresql://postiz:geheim@db:5432/postiz
      - REDIS_URL=redis://redis:6379
      - JWT_SECRET=langer-zufaelliger-key
      - MAIN_URL=https://social.deine-domain.de
      - FRONTEND_URL=https://social.deine-domain.de
      - NEXT_PUBLIC_BACKEND_URL=https://social.deine-domain.de/api
      - OPENAI_API_KEY=ollama            # Trick: Ollama ist API-kompatibel
      - OPENAI_BASE_URL=http://ollama:11434/v1
      - BACKEND_INTERNAL_URL=http://postiz:5000
    volumes: [postiz_data:/app/uploads]
    depends_on: [db, redis]
    restart: always

  db:
    image: postgres:16
    environment:
      POSTGRES_USER: postiz
      POSTGRES_PASSWORD: geheim
      POSTGRES_DB: postiz
    volumes: [pg_data:/var/lib/postgresql/data]
    restart: always

  redis:
    image: redis:7
    volumes: [redis_data:/data]
    restart: always

volumes:
  postiz_data:
  pg_data:
  redis_data:

Here’s the trick: Postiz has built-in OpenAI integration for AI posts. By pointing OPENAI_BASE_URL at Ollama, your AI runs entirely locally.

Linking channels

In the UI, go to Channels → Add Channel and enter OAuth tokens or app credentials for each platform. A few notes:

  • X/Twitter: Requires a developer account and app keys. Free API tier is sufficient for posting.
  • LinkedIn: Create a LinkedIn app and generate OAuth tokens.
  • Mastodon: The easiest integration. Just provide the instance URL and access token.
  • Discord/Telegram: Use bot tokens. Postiz posts as a bot to your servers and channels.
  • Instagram/TikTok: Require business accounts and app review. More involved setup.

AI content generation

Postiz includes AI features built-in (when OPENAI_BASE_URL points to Ollama):

  • Post generator: Enter a topic and the AI suggests post variations.
  • Enhancement: Refine raw text with AI polish.
  • Hashtags: AI recommends relevant tags.
  • Channel adaptation: One post adapted by AI for each channel’s tone (formal for LinkedIn, punchy for X).

n8n workflow: Blog to social

RSS trigger: new blog article
    │
    ▼
Ollama: generate summary + 3 post variations
    │
    ▼
Postiz API: create posts for X, LinkedIn, Mastodon, Discord
    │
    ▼
Scheduled: Postiz publishes at optimal time
import requests

POSTIZ = "https://social.deine-domain.de"
HEADERS = {"Authorization": "Bearer DEIN_API_KEY"}

# Create and schedule post
requests.post(f"{POSTIZ}/api/posts", headers=HEADERS, json={
    "type": "schedule",
    "date": "2026-09-25T10:00:00Z",
    "posts": [{
        "integration": {"id": "X_CHANNEL_ID"},
        "value": [{"content": "New article: Local AI bots for Telegram...",
                   "image": []}]
    }]
})

Security

  • API keys: Social media credentials stored in Postiz are sensitive. Use HTTPS and restrict access.
  • OAuth tokens: Stored in the Postiz database. Back up your database and protect access.
  • Not public: Your Postiz instance should be private for you and your team, not open for public registration.

Postiz vs. alternatives

ToolStrengthWeakness
PostizModern, active, many channels, AI built-inYoung, some channels tricky (Meta)
BufferMature, simpleCloud-only, expensive per channel
MixpostOpen source, Laravel-basedFewer channels, less active
HootsuiteEnterprise-readyExpensive, cloud-only

Further reading

Key takeaways:

  • Postiz is open-source Buffer: one post goes to all channels, scheduled and automated.
  • Built-in AI features work with Ollama (OpenAI-compatible API).
  • API plus webhooks enable content pipelines: blog to AI-generated post to auto-scheduling.
  • Meta channels (Instagram/Facebook) require business accounts and app review.
  • The self-hosted social media solution for content creators and small teams.

FAQ

Is Postiz free?

Yes. It’s open source (Apache 2.0) and completely free when self-hosted. There is a cloud-hosted version, but the self-hosted variant includes all features.

Which channels are supported?

X, LinkedIn, Instagram, Facebook, TikTok, YouTube, Mastodon, Reddit, Discord, Slack, Telegram, Pinterest, Threads, Bluesky. One of the broadest channel lists among open-source tools.

AI features locally?

Yes. The built-in AI features (post generator, enhancements, hashtags) use the OpenAI API. By setting OPENAI_BASE_URL to Ollama, everything runs locally.

Do Instagram and Facebook work?

Yes, but with more setup: Facebook developer app, business account, and app review. Mastodon, X, LinkedIn, and Discord are much simpler to configure.

Are there analytics?

Basic analytics per channel (likes, shares, views). For deeper analytics, use the native platform tools or Matomo tracking.

Team features?

Yes. Workspaces, roles, and approval workflows (draft to review to publish). Great for agencies and content teams.

Sources and further reading

Back to Blog
Share:

Related Posts