AI Content & SEO Optimizer
AI-Powered Content Assistant & SEO Optimizer WordPress plugin that helps content creators and marketers generate, optimize, and improve their content using artificial intelligence while providing real-time SEO recommendations.
Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/mejba13/ai-content-seo-optimizer/archive/refs/heads/main.zipA comprehensive WordPress plugin for AI-powered content generation and real-time SEO optimization.
Overview
AI Content & SEO Optimizer helps content creators and marketers generate high-quality, SEO-optimized content using artificial intelligence. The plugin provides real-time SEO analysis, content optimization suggestions, and intelligent recommendations.
Features
Core Features (Implemented)
- ✅ AI Content Generation - Generate blog posts, product descriptions, meta descriptions, and more
- ✅ Real-Time SEO Analysis - Analyze content for SEO best practices
- ✅ Content Optimization - Improve existing content for clarity, tone, and engagement
- ✅ Keyword Research - AI-powered keyword suggestions
- ✅ Internal Linking Suggestions - Smart recommendations for internal links
- ✅ Readability Analysis - Flesch Reading Ease scoring
- ✅ Token Usage Tracking - Monitor API usage and costs
- ✅ Modern UI Design System - Clean, accessible, professional interface
Supported AI Providers
- OpenAI (GPT-4, GPT-3.5-turbo)
- Anthropic (Claude 3)
- Google PaLM (configurable)
System Requirements
- WordPress: 6.0 or higher
- PHP: 7.4 or higher
- Node.js: 16.x or higher (for development)
- NPM: 8.x or higher (for development)
Installation
From WordPress Admin
- Upload the
ai-content-seo-optimizerfolder to/wp-content/plugins/ - Activate the plugin through the 'Plugins' menu in WordPress
- Go to AI Content & SEO > Settings to configure your API key
- Start generating content!
Using WP-CLI
wp plugin install ai-content-seo-optimizer --activate
Configuration
1. API Setup
Navigate to WordPress Admin > AI Content & SEO > Settings
- Select your preferred AI provider (OpenAI or Anthropic)
- Enter your API key
- Configure default settings:
- Content tone
- Word count
- SEO target score
- Token limits
2. Get API Keys
OpenAI:
- Visit https://platform.openai.com/api-keys
- Create a new API key
- Copy and paste into plugin settings
Anthropic:
- Visit https://console.anthropic.com/settings/keys
- Generate an API key
- Copy and paste into plugin settings
Usage
Content Generation
- Go to AI Content & SEO > Content Generator
- Enter your topic and select content type
- Choose tone and target word count
- Add keywords (optional)
- Click Generate Content
- Review and edit the generated content
- Insert into your post or page
SEO Analysis
- Open any post or page in the editor
- Find the SEO Analyzer metabox
- Enter your focus keyword
- Click Analyze
- Review SEO score and recommendations
- Implement suggested improvements
Content Optimization
- Select text in your content
- Click Optimize
- Choose optimization type:
- Improve Clarity
- Improve Tone
- SEO Optimization
- Fix Grammar
- Increase Engagement
- Review suggestions
- Apply changes
Development
Project Structure
ai-content-seo-optimizer/
├── ai-content-seo-optimizer.php # Main plugin file
├── includes/ # PHP classes
│ ├── class-core.php # Core functionality
│ ├── class-ai-engine.php # AI API integration
│ ├── class-seo-analyzer.php # SEO analysis
│ ├── class-content-optimizer.php # Content optimization
│ ├── class-keyword-research.php # Keyword research
│ └── class-settings.php # Settings management
├── admin/ # Admin interface
│ ├── class-admin.php # Admin controller
│ └── views/ # Admin templates
├── assets/ # Compiled assets
│ ├── css/ # Stylesheets
│ └── js/ # JavaScript
├── src/ # React/TypeScript source
│ ├── components/ # React components
│ ├── hooks/ # Custom React hooks
│ ├── utils/ # Utility functions
│ ├── types/ # TypeScript types
│ ├── api/ # API utilities
│ └── index.tsx # Entry point
├── languages/ # i18n translations
├── package.json # Node dependencies
├── webpack.config.js # Build configuration
├── tsconfig.json # TypeScript config
└── README.md # This file
Building from Source
# Navigate to plugin directory
cd wp-content/plugins/ai-content-seo-optimizer
# Install dependencies
npm install
# Development build (with watch)
npm run start
# Production build
npm run build
Database Tables
The plugin creates two custom tables:
wp_aicso_generation_history
- Stores AI content generation history
- Tracks token usage
- Links to posts
wp_aicso_seo_history
- Stores SEO analysis results
- Tracks SEO scores over time
- Stores recommendations
REST API Endpoints
All endpoints are prefixed with /wp-json/aicso/v1/
| Endpoint | Method | Description |
|---|---|---|
/generate |
POST | Generate AI content |
/analyze-seo |
POST | Analyze content for SEO |
/optimize |
POST | Optimize content |
/settings |
GET | Get current settings |
/settings |
POST | Update settings |
Hooks & Filters
Actions:
// Run after plugin initialization
do_action('aicso_init');
// Run daily for cleanup
do_action('aicso_cleanup_old_data');
Filters:
// Modify available content types
apply_filters('aicso_content_types', $types);
// Modify content tones
apply_filters('aicso_content_tones', $tones);
// Modify generation prompt
apply_filters('aicso_generation_prompt', $prompt, $topic, $content_type, $tone, $word_count, $keywords);
// Modify optimization prompt
apply_filters('aicso_optimization_prompt', $prompt, $content, $optimization_type, $keyword);
Design System
The plugin follows a Modern Classic Aesthetic with:
- Clean, minimalist interface
- High contrast for accessibility
- Generous white space
- Professional typography
- Smooth animations
- WCAG 2.1 AA compliance
Color Palette
--aicso-primary: #2563eb /* Primary blue */
--aicso-success: #10b981 /* Success green */
--aicso-warning: #f59e0b /* Warning orange */
--aicso-error: #ef4444 /* Error red */
Typography
- Font Stack: System fonts (San Francisco, Segoe UI, Roboto)
- Base Size: 15px
- Headings: 600 weight, tight letter spacing
- Body: 400 weight, 1.6 line height
Security
- All user input is sanitized using WordPress functions
- Nonce verification on all AJAX/REST requests
- Capability checks on all admin pages
- API keys stored encrypted
- Prepared SQL statements
- CORS properly configured
Performance
- Code splitting for optimal load times
- Lazy loading of components
- Efficient database queries with indexes
- Transient caching for API responses
- Automatic cleanup of old data
Accessibility
- WCAG 2.1 AA compliant
- Full keyboard navigation support
- Screen reader friendly
- High contrast colors
- Focus indicators on all interactive elements
- Semantic HTML structure
Troubleshooting
Plugin won't activate
- Check PHP version (7.4+ required)
- Check WordPress version (6.0+ required)
- View error logs in
wp-content/debug.log
Content generation fails
- Verify API key is correct
- Check if you've reached token limits
- Ensure API provider is selected correctly
- Check network connectivity
SEO analysis not working
- Ensure you have content in the editor
- Check browser console for JavaScript errors
- Verify WordPress REST API is accessible
Build errors
- Delete
node_modulesfolder - Run
npm cache clean --force - Run
npm installagain - Check Node.js version (16+ required)
Support & Contributing
Getting Help
- Check documentation
- Search existing issues
- Create a new issue with:
- WordPress version
- PHP version
- Plugin version
- Steps to reproduce
- Error messages
Development Workflow
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
Coding Standards
- Follow WordPress Coding Standards
- Use ESLint for JavaScript/TypeScript
- Write meaningful commit messages
- Add PHPDoc comments
- Include unit tests for new features
Changelog
Version 1.0.0 (2025-11-03)
Initial Release
- AI content generation (OpenAI, Anthropic)
- Real-time SEO analysis
- Content optimization
- Keyword research
- Internal linking suggestions
- Token usage tracking
- Modern UI with design system
- Full TypeScript/React architecture
- WordPress 6.0+ support
License
GPL v2 or later
Copyright (C) 2025 Engr Mejba Ahmed
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
Credits
Developed by Engr Mejba Ahmed
- Website: https://mejba.me
- Email: contact@mejba.me
Technologies Used
- WordPress
- React 18
- TypeScript
- Webpack
- Framer Motion
- OpenAI API
- Anthropic API
Roadmap
Phase 2 (Planned)
- [ ] Content calendar integration
- [ ] Team collaboration features
- [ ] Custom AI training
- [ ] Advanced analytics dashboard
- [ ] WordPress Multisite support
Phase 3 (Future)
- [ ] Mobile app
- [ ] Video content optimization
- [ ] Voice-to-content generation
- [ ] Social media optimization
- [ ] WooCommerce product descriptions
- [ ] Automated content refreshing
FAQ
Q: Does this plugin store my API key securely? A: Yes, API keys are encrypted before storage in the database.
Q: Can I use multiple AI providers? A: You can configure one provider at a time, but switching is easy in settings.
Q: How is token usage calculated? A: Token usage is tracked from the AI provider's API response and stored in the database.
Q: Can I customize the SEO scoring algorithm? A: Yes, through filters and settings you can adjust weights and thresholds.
Q: Does this work with Gutenberg/block editor? A: Yes, the plugin provides metaboxes that work with both classic and block editors.
Q: Is the plugin translation-ready? A: Yes, all strings are internationalized and ready for translation.
Made with ❤️ for WordPress community