Last updated: March 16, 2026
Move Stable Diffusion to Midjourney by translating your custom models to Midjourney’s style tokens, converting your prompts to their format, and adjusting sampling parameters. This guide shows the prompt transformation and configuration changes that achieve equivalent results.
Moving your AI image generation workflows from Stable Diffusion to Midjourney requires understanding the fundamental differences between these two platforms. While Stable Diffusion runs locally with extensive customization options, Midjourney operates through Discord with its own prompt syntax and generation pipeline. This guide walks you through converting your existing workflows step by step.
Prerequisites
Before you begin, make sure you have the following ready:
- A computer running macOS, Linux, or Windows
- Terminal or command-line access
- Administrator or sudo privileges (for system-level changes)
- A stable internet connection for downloading tools
Step 1: Understand the Platform Differences
Stable Diffusion gives you complete control over the generation process. You can modify models, embed custom embeddings, and fine-tune every parameter through APIs like Automatic1111 or ComfyUI. Midjourney abstracts much of this complexity, focusing on producing high-quality results through its curated model versions and Discord-based interface.
The key challenge lies in translating your existing Stable Diffusion prompts, Loras, and workflow patterns into Midjourney’s equivalent functionality. This involves understanding how prompt weighting, style modifiers, and generation parameters map between the two systems.
Step 2: Converting Stable Diffusion Prompts to Midjourney Syntax
One of the first hurdles you’ll face is converting your existing Stable Diffusion prompts. Midjourney uses a different syntax for specifying weights and parameters. Here’s a Python tool that helps automate this conversion:
#!/usr/bin/env python3
"""
Prompt converter: Stable Diffusion to Midjourney syntax
Converts SD-style prompts to Midjourney-compatible format.
"""
import re
import sys
def convert_sd_to_mj_prompt(sd_prompt: str) -> str:
"""
Convert Stable Diffusion prompt to Midjourney syntax.
Args:
sd_prompt: The Stable Diffusion prompt string
Returns:
Midjourney-compatible prompt string
"""
# Handle parentheses for emphasis (SD uses () while MJ uses ::)
# In SD: (word) = 1.1 weight, ((word)) = 1.21 weight
# In MJ: ::word = 1.0, ::word::0.5 = 0.5 weight
# Convert emphasis parentheses to Midjourney's double colons
result = sd_prompt
# Handle negative prompts - move them after --no flag
negative_match = re.search(r'\[(.*?)\]', result)
negative_prompt = ""
if negative_match:
negative_prompt = negative_match.group(1)
result = result[:negative_match.start()] + result[negative_match.end():]
# Convert weight syntax: (word) -> ::word
# This is a simplified conversion
result = re.sub(r'\((.*?)\)', r'::\1', result)
# Clean up multiple colons
result = re.sub(r'::+', '::', result)
# Add negative prompt as --no parameter
if negative_prompt:
result = f"{result} --no {negative_prompt.replace(', ', ',')}"
return result.strip()
def convert_lora_reference(lora_string: str) -> str:
"""
Convert Stable Diffusion LoRA references to Midjourney's style references.
In SD: <lora:model_name:0.5>
In MJ: Use --sref or --style parameters
"""
lora_pattern = r'<lora:([^:]+):([0-9.]+)>'
matches = re.findall(lora_pattern, lora_string)
if not matches:
return ""
# For each LoRA, we'll create a style note
# Midjourney doesn't have direct LoRA support but handles styles differently
style_refs = []
for name, weight in matches:
style_refs.append(f"# LoRA '{name}' was weight {weight} in SD")
return "\n".join(style_refs)
if __name__ == "__main__":
# Example usage
sd_example = "a beautiful landscape with mountains, (sunset:1.2), [ugly, deformed]"
mj_prompt = convert_sd_to_mj_prompt(sd_example)
print(f"SD Prompt: {sd_example}")
print(f"MJ Prompt: {mj_prompt}")
This script handles the basic conversions. Save it as prompt_converter.py and run it with your existing prompts:
chmod +x prompt_converter.py
python3 prompt_converter.py
Step 3: Create Equivalent Workflow Configurations
Your Stable Diffusion workflows likely use config files to manage model paths, VAE settings, and sampling parameters. Here’s how to create equivalent configurations for Midjourney through Discord bot commands:
# midjourney-workflow-config.yaml
# Equivalent workflow configuration for Midjourney operations
# Note: Midjourney uses Discord, so this config documents equivalent settings
workflow_version: "1.0"
platform: "midjourney"
# These map SD parameters to MJ equivalents:
parameter_mapping:
sampler:
# SD samplers to MJ style presets
dpm_2m: "--fast" # Faster generation
dpm_++_2m: "--relaxed" # Quality focused
euler_a: "--creative" # More creative interpretations
steps:
# SD steps to MJ quality tiers
20: "--fast"
30: "--relaxed"
50: "--quality .5"
100: "--quality 1"
cfg_scale:
# CFG strength to MJ's --iw parameter
7: "--iw 0.5"
12: "--iw 0.75"
20: "--iw 1.0"
# Style presets that approximate SD model differences
style_presets:
realistic: "--style raw"
anime: "--niji"
illustration: "--illustrated"
photographic: "--photo"
Step 4: Build a Batch Migration Pipeline
When migrating large prompt libraries, you’ll want a batch processing solution. This Bash script processes directories of prompts and converts them systematically:
#!/bin/bash
# Batch prompt converter for migrating Stable Diffusion prompts to Midjourney
INPUT_DIR="sd_prompts"
OUTPUT_DIR="mj_prompts"
LOG_FILE="migration_log.txt"
# Create output directory
mkdir -p "$OUTPUT_DIR"
# Initialize log
echo "Prompt Migration - $(date)" > "$LOG_FILE"
# Process each prompt file
for prompt_file in "$INPUT_DIR"/*.txt; do
if [ -f "$prompt_file" ]; then
filename=$(basename "$prompt_file")
echo "Processing: $filename"
# Read prompt and convert
while IFS= read -r line; do
# Skip empty lines and comments
if [[ -n "$line" && ! "$line" =~ ^# ]]; then
# Convert using our Python script
python3 prompt_converter.py "$line" >> "$OUTPUT_DIR/${filename%.txt}_mj.txt"
fi
done < "$prompt_file"
echo "Converted: $filename -> ${filename%.txt}_mj.txt" >> "$LOG_FILE"
fi
done
echo "Migration complete. Results in $OUTPUT_DIR"
echo "Log saved to $LOG_FILE"
Run this with:
chmod +x batch_convert.sh
./batch_convert.sh
Step 5: Set Up Equivalent Image Processing
Stable Diffusion often uses img2img for variations and inpainting. Midjourney handles these through different parameters and the Discord interface. Here’s how to map these workflows:
#!/usr/bin/env python3
"""
Image processing equivalents: SD img2img -> Midjourney
Maps Stable Diffusion image-to-image workflows to Midjourney pan/zoom/vary.
"""
class ImageWorkflowMapper:
"""Maps SD image operations to Midjourney equivalents."""
def __init__(self):
self.operations = {
"img2img": self.map_img2img,
"inpainting": self.map_inpainting,
"outpainting": self.map_outpainting,
"upscale": self.map_upscale
}
def map_img2img(self, strength: float, prompt: str) -> str:
"""
Convert SD img2img to Midjourney's --iw parameter.
In SD: denoise strength (0.0-1.0)
In MJ: --iw (0.0-2.0) - image weight
"""
# Map SD strength to MJ image weight
# Lower strength in SD = higher influence from original
mj_iw = (1.0 - strength) * 2.0
return f"{prompt} --iw {mj_iw:.2f}"
def map_inpainting(self, mask_area: dict, prompt: str) -> str:
"""
Convert SD inpainting to Midjourney.
MJ doesn't have direct inpainting, use describe/blend instead.
"""
# Use /describe to analyze the base image
return f"# Use /describe command\n# Then /imagine with: {prompt}"
def map_outpainting(self, direction: str, prompt: str) -> str:
"""
Convert SD outpainting to Midjourney's pan operations.
Directions: up, down, left, right
"""
pan_map = {
"up": "--pan up",
"down": "--pan down",
"left": "--pan left",
"right": "--pan right"
}
pan_arg = pan_map.get(direction.lower(), "")
return f"{prompt} {pan_arg}"
def map_upscale(self, scale: int, prompt: str) -> str:
"""
Convert SD upscaling to Midjourney's upscale options.
MJ: --upbeta, --upalpha, --uplight
"""
upscale_map = {
2: "--upbeta",
4: "--upalpha",
1.5: "--uplight"
}
upscale_arg = upscale_map.get(scale, "--upbeta")
return f"{prompt} {upscale_arg}"
# Example usage
if __name__ == "__main__":
mapper = ImageWorkflowMapper()
# Convert an img2img workflow
sd_prompt = "a serene lake at sunset"
sd_strength = 0.7
mj_result = mapper.map_img2img(sd_strength, sd_prompt)
print(f"SD: img2img with strength {sd_strength}")
print(f"MJ: {mj_result}")
Step 6: Manage Workflow State and History
Unlike Stable Diffusion’s local file-based workflow storage, Midjourney stores job history in Discord. Here’s a Python class for tracking your migrated workflows:
#!/usr/bin/env python3
"""
Workflow tracker for Midjourney jobs
Maintains local database of generated images and prompts.
"""
import json
from datetime import datetime
from pathlib import Path
from typing import Optional
class MJWorkflowTracker:
"""Tracks Midjourney generation history for workflow migration."""
def __init__(self, db_path: str = "mj_workflow_db.json"):
self.db_path = Path(db_path)
self.data = self._load_database()
def _load_database(self) -> dict:
"""Load existing database or create new one."""
if self.db_path.exists():
with open(self.db_path, 'r') as f:
return json.load(f)
return {"jobs": [], "prompts": []}
def _save_database(self):
"""Persist database to disk."""
with open(self.db_path, 'w') as f:
json.dump(self.data, f, indent=2)
def add_job(self, prompt: str, job_id: str,
seed: Optional[int] = None,
sd_source: Optional[str] = None):
"""
Record a new Midjourney job.
Args:
prompt: The Midjourney prompt used
job_id: Discord message ID for this job
seed: The seed value if available
sd_source: Original SD prompt if migrated
"""
job_entry = {
"job_id": job_id,
"prompt": prompt,
"seed": seed,
"sd_source": sd_source,
"timestamp": datetime.now().isoformat(),
"status": "completed"
}
self.data["jobs"].append(job_entry)
self._save_database()
def find_similar(self, prompt: str, limit: int = 5):
"""Find similar prompts in history."""
# Simple substring matching
results = [
job for job in self.data["jobs"]
if prompt.lower() in job["prompt"].lower()
]
return results[:limit]
def export_prompts(self, output_file: str):
"""Export all prompts to a text file."""
with open(output_file, 'w') as f:
for job in self.data["jobs"]:
f.write(f"{job['prompt']}\n")
if job.get('sd_source'):
f.write(f"# From SD: {job['sd_source']}\n")
f.write("\n")
# Usage example
if __name__ == "__main__":
tracker = MJWorkflowTracker()
# Add a migrated job
tracker.add_job(
prompt="a mountain landscape at sunset::1.2 --ar 16:9 --v 6",
job_id="123456789012345678",
seed=42,
sd_source="a beautiful mountain landscape, sunset, highly detailed"
)
# Find similar prompts
similar = tracker.find_similar("mountain landscape")
print(f"Found {len(similar)} similar prompts")
Step 7: Practical Migration Checklist
Use this checklist when moving your workflows:
-
Export existing prompts - Extract all prompts from your SD database
-
Convert prompt syntax - Run through the Python converter script
-
Map parameters - Translate sampling, steps, and CFG settings
-
Document style preferences - Note which LoRAs and embeddings you used
-
Set up Discord - Configure your Midjourney bot channels
-
Test conversions - Run sample prompts and compare outputs
-
Build reference library - Use the tracker to maintain consistency
-
Batch process - Migrate entire prompt collections systematically
Troubleshooting
Configuration changes not taking effect
Restart the relevant service or application after making changes. Some settings require a full system reboot. Verify the configuration file path is correct and the syntax is valid.
Permission denied errors
Run the command with sudo for system-level operations, or check that your user account has the necessary permissions. On macOS, you may need to grant terminal access in System Settings > Privacy & Security.
Connection or network-related failures
Check your internet connection and firewall settings. If using a VPN, try disconnecting temporarily to isolate the issue. Verify that the target server or service is accessible from your network.
Frequently Asked Questions
How long does it take to move stable diffusion workflows to midjourney?
For a straightforward setup, expect 30 minutes to 2 hours depending on your familiarity with the tools involved. Complex configurations with custom requirements may take longer. Having your credentials and environment ready before starting saves significant time.
What are the most common mistakes to avoid?
The most frequent issues are skipping prerequisite steps, using outdated package versions, and not reading error messages carefully. Follow the steps in order, verify each one works before moving on, and check the official documentation if something behaves unexpectedly.
Do I need prior experience to follow this guide?
Basic familiarity with the relevant tools and command line is helpful but not strictly required. Each step is explained with context. If you get stuck, the official documentation for each tool covers fundamentals that may fill in knowledge gaps.
Will this work with my existing CI/CD pipeline?
The core concepts apply across most CI/CD platforms, though specific syntax and configuration differ. You may need to adapt file paths, environment variable names, and trigger conditions to match your pipeline tool. The underlying workflow logic stays the same.
Where can I get help if I run into issues?
Start with the official documentation for each tool mentioned. Stack Overflow and GitHub Issues are good next steps for specific error messages. Community forums and Discord servers for the relevant tools often have active members who can help with setup problems.
Related Articles
- Move Stable Diffusion Workflows to Midjourney
- How to Move Midjourney Style References to Stable Diffusion
- Stable Diffusion vs Midjourney for Character Design
- DALL-E 3 vs Stable Diffusion for Illustrations
- Stable Diffusion ComfyUI vs Automatic1111 Comparison
- Claude Code for Faker.js Test Data Workflow Guide
Built by theluckystrike — More at zovo.one