WP Manifestindependent plugin directory
manifest / ai / wordpress-perplexity-provider

Perplexity Provider

Adds Perplexity as an AI provider for the WordPress AI Client.

by Coen Jacobs · github.com/coenjacobs/wordpress-perplexity-provider

0stars
1release downloads
0forks

Install

The author publishes release zips, so WP-CLI can install straight from GitHub:

wp plugin install https://github.com/coenjacobs/wordpress-perplexity-provider/releases/download/0.1.0/perplexity-provider-0.1.0.zip

Readme

Perplexity Provider for WordPress

A WordPress plugin that registers Perplexity as an AI provider for the WordPress AI Client, starting with the Sonar API — search-augmented AI models that deliver real-time, accurate answers.

Requirements

  • WordPress 7.0 or higher
  • PHP 7.4 or higher
  • AI Experiments plugin (for running experiments through the WordPress admin)

Installation

Clone this repository into your wp-content/plugins/ directory:

git clone https://github.com/coenjacobs/wordpress-perplexity-provider.git wp-content/plugins/perplexity-provider
cd wp-content/plugins/perplexity-provider
composer install

Activate the plugin through the WordPress admin panel or WP-CLI:

wp plugin activate perplexity-provider

Configuration

API Key

The API key can be configured in three ways (in order of precedence):

  1. Environment variable: Set PERPLEXITY_SONAR_API_KEY in your environment
  2. PHP constant: Define PERPLEXITY_SONAR_API_KEY in wp-config.php
  3. Settings page: Enter it at Settings > Perplexity in the WordPress admin

Model Selection

Visit Settings > Perplexity to enable specific models. The following Sonar models are available:

  • Sonar — Fast, lightweight search-augmented model
  • Sonar Pro — Advanced search-augmented model with higher quality
  • Sonar Reasoning Pro — Extended thinking with search augmentation
  • Sonar Deep Research — Multi-step research with comprehensive answers

Only enabled models are exposed to the WordPress AI Client and available for use in AI Experiments.

How It Works

The plugin registers a single provider (perplexity-sonar) with the WordPress AI Client registry on the init hook. All Sonar models use the OpenAI-compatible /chat/completions endpoint at https://api.perplexity.ai.

The model list is hardcoded since Perplexity does not provide a /models API endpoint.

Development Environment

The project includes a Docker-based development environment. No PHP, Composer, or other tools are needed on the host machine.

Quick Start

make build    # Build the Docker image
make setup    # Full setup: download WordPress, configure, install, activate plugin

This gives you a working WordPress 7.0-beta2 installation at http://localhost:8083 (admin/admin) with the plugin activated.

Makefile Targets

Target Purpose
make build Build the Docker image
make setup Full clean setup: download WordPress, configure, install, activate plugin
make up / make down Start/stop containers
make clean-wp Stop containers and wipe the WordPress directory
make composer Run composer install for the plugin
make activate Activate the plugin via WP-CLI

Docker Stack

  • PHP: 8.5 CLI Alpine with built-in web server
  • Database: MariaDB 11
  • WordPress: 7.0-beta2 (downloaded via curl + tar)

Volume Mounts

  • ./wordpress//var/www/html — WordPress root (gitignored)
  • .//var/www/html/wp-content/plugins/perplexity-provider — plugin source
  • ./docker/mariadb/data//var/lib/mysql — database storage (gitignored)

Read the full README on GitHub →

Releases

TagPublishedAssetDownloads
0.1.0 Feb 28, 2026 perplexity-provider-0.1.0.zip 1