How to connect WordPress to external apps
WordPress connects to external apps through its REST API. Use an application password when an app needs to read or change WordPress data, and send webhooks when WordPress needs to notify another service. For several apps or no-code workflows, a connector plugin is faster.
- 01Choose the connection direction
- 02Check the app’s API requirements
- 03Create a WordPress application password
- 04Build the manual connection
- 05Test the complete workflow
- 06Use Bit Integrations Pro for speed
What you need
- A WordPress site using HTTPS
- Administrator access to WordPress
- An account and API details for the external app
- A backup or staging site for testing code
Choose the connection direction
First decide whether the external app needs to read or change WordPress, whether WordPress needs to send data to the app, or whether you need both directions. The WordPress REST API exposes content as JSON and supports remote HTTP requests, so it is the normal starting point for app connections.
For a single, simple transfer, a small custom integration can be fine. If you need several triggers, field mappings, retries, logs or non-technical users to manage the workflow, plan to use an integration plugin instead.
Check the app’s API requirements
In the external app’s documentation, identify its API endpoint, required data fields, authentication method and rate limits. Decide what should happen when a request fails and whether the app accepts incoming webhooks.
Do not guess field names or endpoint URLs. A successful connection can still create incomplete records if the external service expects a different date format, status value or email field.
Create a WordPress application password
If the external app must access private WordPress data, create an application password from Users, open the account that will be used, and add a new application password. WordPress introduced application passwords in version 5.6; they are intended for API authentication, are displayed only when created, and can be revoked separately from the user’s main password. Use HTTPS and store the value in the external app’s secure credential field.
Use a dedicated user with only the capabilities the connection needs. Never put the site owner’s normal password in an integration, and do not paste an application password into public code, screenshots or support posts.
Build the manual connection
For app-to-WordPress access, give the service the site’s REST API base, usually beginning with https://example.com/wp-json/, together with the WordPress username and application password. The exact route depends on the data: posts, pages, media and other built-in resources have documented REST routes. Test a read request before allowing create, update or delete actions.
For WordPress-to-app delivery, a developer normally adds a small custom plugin or site-specific integration that sends a POST request to the external service. WordPress provides wp_remote_post() and response helpers for this; the integration should check the response code, record failures and avoid sending sensitive data unnecessarily.
Test the complete workflow
Run the workflow with test data and verify the result in both systems. Check text, dates, IDs, HTML, attachments and duplicate handling. Then test a failed request by using an invalid credential or temporarily unavailable endpoint, and confirm that the failure is visible rather than silently lost.
The common Friday failure is a security plugin, host firewall or caching layer blocking /wp-json/, the authorisation header or a webhook route. A 401 usually points to missing or invalid authentication; a 403 usually means the authenticated account lacks permission or another security rule is refusing the request. Check the server and plugin logs before changing code.
Use Bit Integrations Pro for speed
For the fast route, install and activate Bit Integrations Pro, then create a workflow with a WordPress trigger, the external app action and any field mappings or conditions. It is suited to no-code connections with services such as Google Sheets, Zapier and Mailchimp, and can also work with webhooks.
This route is preferable when you need several app connections, reusable triggers and actions, or an interface that someone else can maintain. Keep the manual REST API route for one small, stable integration where you control the code and are prepared to maintain authentication and error handling.
Let Bit Integrations Pro do it
No-code triggers, actions, and webhooks for syncing WordPress with apps like Google Sheets, Zapier, and Mailchimp.
Sources
- developer.wordpress.org /rest-api/?utm_source=openai
- developer.wordpress.org /rest-api/using-the-rest-api/authentication/?utm_source=open…
- developer.wordpress.org /rest-api/reference/?utm_source=openai
- developer.wordpress.org /apis/making-http-requests/posting-data-to-an-external-servi…
- wordpress.org /support/topic/application-password-problem/?utm_source=open…
- developer.wordpress.org /advanced-administration/security/application-passwords/?utm…
Questions
- Can WordPress connect to an external app without a plugin?
- Yes, but the manual route normally requires custom code. An external app can call the WordPress REST API using HTTPS and an application password, while WordPress code can send data to another service with an HTTP POST request. This is reasonable for one simple workflow, but a plugin is easier when you need triggers, field mapping, retries or logs.
- What credentials should an external app use with WordPress?
- Use a WordPress application password rather than the user’s normal password. Create it for a dedicated account with the minimum required role, transmit it only over HTTPS, store it in the app’s protected credential settings and revoke it when the connection is no longer needed. Application passwords are designed for API access and can be revoked individually.
- Why does a WordPress integration return 401 or 403 errors?
- A 401 generally means the request is not authenticated correctly, such as a missing authorisation header, wrong username or invalid application password. A 403 generally means the authenticated user is not allowed to perform that action, although security plugins, firewalls and hosting rules can also block REST routes. Check the exact JSON error and server logs before changing permissions.
- How do I send WordPress data to another app?
- You send it as an HTTP POST to the other app’s API or webhook URL. A custom WordPress plugin can use <code>wp_remote_post()</code>, pass the required JSON or form data, add the service’s authentication header and check the response code. The integration should log failures and prevent duplicate submissions where the external service supports an idempotency key.
- Is a webhook or REST API better for connecting WordPress apps?
- Neither is always better. Use the REST API when an app needs to query, create or update WordPress resources. Use a webhook when WordPress needs to notify another service immediately after an event. Many useful workflows use both: a webhook starts the process, then the receiving app calls the REST API for the full record.