Ghost Integration
Connect your Ghost blog to Forest SEO for automated content publishing using Admin API Key or Staff Access Token.
Connect your Ghost blog to Forest SEO for automated content publishing. Ghost integration supports two authentication methods for maximum flexibility.
โ Prerequisites
Before starting, ensure you have:
| Requirement | Details | Documentation |
|---|---|---|
| Ghost Instance | Self-hosted or Ghost Pro | ghost.org |
| Ghost Version | 3.0 or higher | Check in Ghost admin |
| Admin Access | Administrator role | Required for API key creation |
| Admin URL | Ghost admin panel URL | Usually https://yourblog.com/ghost/ |
๐ Authentication Methods
Ghost supports two authentication methods:
Method 1: Admin API Key โญ Recommended
Format: {id}:{secret}
Example: 63af31d6d5e60cf73bf6730e:a7c4f3e8b2d9a1e6c5f7d8e9a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1
How to Get:
- Login to Ghost admin panel
- Go to Settings โ Integrations
- Click + Add custom integration
- Name it "Forest SEO"
- Copy the Admin API Key (24 hex chars, colon, 64 hex chars)
Method 2: Staff Access Token
Format: JWT token (three base64url parts separated by dots)
When to Use:
- For user-based authentication
- When you need user-specific permissions
- For multi-author workflows
๐ Setup Guide
Step 1: Create Custom Integration in Ghost
Detailed Steps:
-
Access Ghost Admin
- Navigate to
https://yourblog.com/ghost/ - Login with administrator credentials
- Navigate to
-
Create Integration
- Click Settings (gear icon in sidebar)
- Select Integrations tab
- Click + Add custom integration button
- Enter name: "Forest SEO"
- Click Create
-
Copy Credentials
- Admin API Key โ The key in format
id:secret(you'll need this) - API URL โ Your Ghost API endpoint (automatically detected from Admin URL)
- Content API Key โ Not needed for Forest SEO (read-only)
- Admin API Key โ The key in format
Step 2: Connect in Forest SEO
In Forest SEO Dashboard:
-
Navigate to Settings โ Integrations
-
Click "Add Integration"
-
Select "Ghost"
-
Fill in connection details:
| Field | Value | Example |
|---|---|---|
| Name | Integration identifier | "My Ghost Blog" |
| Admin URL | Ghost admin panel URL | https://yourblog.com/ghost/ |
| API Key | Admin API Key from Step 1 | 63af31d6d5e60cf73bf6730e:a7c... |
- Click "Test Connection" to verify
- If successful, click "Save Integration"
โ๏ธ How It Works
API Key Format Validation
Forest SEO validates your API key format:
Admin API Key: Must match pattern [24 hex chars]:[64 hex chars]
63af31d6d5e60cf73bf6730e:a7c4f3e8b2d9a1e6c5f7d8e9a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1
โโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโ
24 hex chars 64 hex chars
Staff Access Token: Must be valid JWT format (three parts separated by dots)
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c
โโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโ โโโโโโโโโโโโโโฌโโโโโโโโโโโโโ โโโโโโโโโโโโฌโโโโโโโโโโโ
Header Payload Signature
๐ Content Publishing
Content Mapping
Forest SEO maps content to Ghost fields automatically:
| Forest SEO Field | Ghost Field | Description |
|---|---|---|
| Title | title | Post title |
| Content | html | Full HTML content |
| Excerpt | custom_excerpt | Summary text |
| Slug | slug | URL-friendly identifier |
| Featured Image | feature_image | Main post image |
| Tags | tags | Post tags/categories |
| Meta Title | meta_title | SEO title tag |
| Meta Description | meta_description | SEO description |
Supported Content Types
Rich Content:
- โ HTML content
- โ Markdown formatting
- โ Images with captions
- โ Code blocks
- โ Embedded media
Ghost Cards:
- โ Image cards
- โ Markdown cards
- โ HTML cards
- โ Bookmark cards
๐งช Testing Your Integration
Connection Test
Test Checklist:
- Click "Test Connection" in integration settings
- Verify:
- Admin URL is correct
- API key format is valid
- Ghost API is reachable
- Write permissions granted
- Review test results
- Fix any issues
- Save integration
Test Publish
Steps:
- In Forest SEO, select an article
- Click "Publish" โ "Ghost"
- Set status to "draft"
- Click "Publish Now"
- Wait for confirmation
- Check Ghost Admin:
- Navigate to Posts section
- Find the published draft
- Verify all content fields
- Check images uploaded correctly
- Review tags and metadata
๐ง Troubleshooting
Common Issues
401 Unauthorized
Problem: Authentication fails
Causes:
- Invalid Admin API Key
- Key was regenerated in Ghost
- Wrong key format
Solutions:
-
Regenerate Key:
- Go to Ghost Settings โ Integrations
- Delete old "Forest SEO" integration
- Create new integration
- Copy new Admin API Key
-
Verify Format:
- Key should be
24hexchars:64hexchars - Contains exactly one colon (
:) - Only lowercase hex characters (0-9, a-f)
- Key should be
404 Not Found
Problem: Ghost API endpoint not found
Causes:
- Incorrect Admin URL
- Ghost instance not running
- Network issues
Solutions:
| Issue | Fix |
|---|---|
| Wrong URL | Use https://yourblog.com/ghost/ (with /ghost/) |
| Missing Slash | Add trailing slash to Admin URL |
| HTTP vs HTTPS | Ensure protocol matches your Ghost setup |
| Domain | Verify domain is correct and accessible |
Invalid API Key Format
Problem: "Invalid API key format" error
Expected Formats:
Admin API Key:
Pattern: /^[a-f0-9]{24}:[a-f0-9]{64}$/
Example: 63af31d6d5e60cf73bf6730e:a7c4f3e8b2d9a1e6c5f7d8e9a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1
Staff Access Token:
Pattern: JWT with 3 parts separated by dots
Example: eyJhbGciOi...{payload}...{signature}
Debugging:
- Check for extra spaces
- Verify colon position (if Admin API Key)
- Ensure entire key was copied
- Try regenerating the key
๐ Ghost-Specific Features
Content Features
Featured Posts:
- Mark posts as featured in Ghost
- Appear in featured section
- Controlled via Ghost settings
Internal Tags:
- Use tags starting with
#for organization #forest-seoโ Identify auto-generated content#review-neededโ Flag for editorial review- Internal tags don't appear publicly
Visibility Options:
- Public โ Visible to everyone
- Members โ Free members and above
- Paid โ Paid subscribers only
๐ Integration with Features
With Content Generation
- Generate AI content
- Publish as draft or public
- Auto-create tags
With Schedules
- Automate publishing
- Batch operations
- Scale to 100+ posts/month
Learn more about Schedules โ
๐ Resources
๐ก Best Practices
API Key Security
- Never share your Admin API Key
- Regenerate keys if compromised
- Use separate integrations for different projects
- Monitor usage in Ghost analytics
Content Publishing
- Test first with draft status
- Review content before publishing
- Use tags for organization
- Set featured images for better engagement
Monitoring
- Check sync status regularly
- Review failed publications in Forest SEO
- Monitor Ghost for published content
- Track performance with Ghost analytics