October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk6 min

How to Build a Custom Appium Plugin

A practical guide to building an Appium plugin package, handling commands safely, activating it locally, and managing distribution.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Build an Appium plugin as a Node.js package: declare Appium as a peer dependency, register the plugin name and exported class in the package metadata, then extend BasePlugin and implement the command behavior you need. Install it locally, activate it explicitly when starting Appium, and test the commands and Appium versions you intend to support. A plugin is inactive until an administrator enables it with appium --use-plugins=plugin-name.

Decide whether an Appium plugin is the right extension

Appium plugins are optional extensions for changing or augmenting server behavior in specialized workflows. They are powerful and opt-in: a plugin can intercept or replace command behavior, so the server administrator should explicitly trust and enable it. Start by identifying the behavior you need and checking whether an existing plugin already provides it. The Appium plugin ecosystem page, dated 2024-07-10 for Appium 2.15, lists examples including Execute Driver, Images, Relaxed Caps, Storage and Universal XML, as well as community plugins for areas such as device-farm session management, gestures, OCR and reporting. Treat that page as examples, not a complete current catalog: Appium Plugins.

Appium’s current plugin-building guide is dated 2026-08-17, and its extension CLI reference is dated 2026-09-10. Compatibility still depends on the Appium release you target. The interface reference cited below is specifically for Appium 2.0; use it to understand concepts, not as proof that a plugin works on every current release.

Create the Node.js package and register its plugin class

Your package needs an Appium peer dependency and an appium metadata object with pluginName and mainClass. The class named by mainClass must be exported and extend BasePlugin from appium/plugin.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
{
  "peerDependencies": {
    "appium": "<range supported by this plugin>"
  },
  "main": "./build/index.js",
  "appium": {
    "pluginName": "example",
    "mainClass": "ExamplePlugin"
  }
}

This is the metadata shape, not a complete manifest. Set the peer-dependency range to the Appium versions you actually support, and add the entry point, module format, build scripts and other package fields your project requires. Do not copy an illustrative Appium 2 version range if you target another release. See Appium’s Building Plugins guide for the current interface and metadata details.

Implement a command handler

To intercept a command a driver already handles, define an asynchronous plugin method with that command’s name. The handler receives next, the session’s driver, and the command arguments. Call await next() when the normal command behavior or the next plugin in the chain should run. You can place plugin logic before or after that call and return its result. If you omit the call, the rest of the behavior chain does not run.

For example, a setUrl handler can inspect the page, run the original command, then return its result:

import { BasePlugin } from 'appium/plugin';

class ExamplePlugin extends BasePlugin {
  async setUrl(next, driver, url) {
    // Optional work before the normal command.
    const result = await next();
    // Optional work after the normal command.
    return result;
  }
}

export { ExamplePlugin };

The example is a starting shape; add only the page inspection or other logic your plugin needs. For broader command inspection, implement async handle(next, driver, cmdName, ...args). A plugin that takes over a command but wants normal proxy behavior to occur should invoke next(). Appium’s Appium 2.0 Plugin interface reference provides background on the interface.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.

Add plugin configuration or scripts if needed

Define custom command-line arguments

Plugin metadata can define custom arguments. Appium prefixes them with --plugin-<name>. For a plugin named pluggo with an argument named electro-port, the server option is --plugin-pluggo-electro-port. The same value can be supplied in configuration under server.plugin.<plugin-name>. Consult the current plugin development guide for the metadata format to declare the arguments.

Expose scripts

A plugin may map script names to JavaScript files in its metadata. Users run a registered script with appium plugin run <name> <script>. This is useful for plugin-provided utilities that are not part of a session command; the extension CLI reference documents script execution at appium driver/plugin.

Install and activate the plugin locally

Appium documents two local development approaches. Choose based on whether you want the extension CLI to manage installation or want an npm project to control the local dependency setup.

Approach How to use it What it controls
Install the local directory appium plugin install --source=local /path/to/your/plugin Appium’s extension CLI installs the local package.
Keep Appium and the plugin in one npm project Add both as development dependencies, then start Appium using npm exec appium or npx appium. Your project’s npm dependency setup controls the local packages and versions.

After installation, explicitly activate the plugin when starting the server:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
appium --use-plugins=example

Use the plugin name registered in package metadata. Installing a plugin does not activate it. After changing plugin code, restart the server to load the edits. Alternatively, set APPIUM_RELOAD_EXTENSIONS if you want Appium to request extension reloads when a new session starts. The local installation and reload options are described in the Building Plugins guide.

Test behavior and compatibility before sharing

Appium’s guide recommends local installation to see how a plugin behaves before publishing. A practical test plan should cover the specific behavior and supported versions rather than assume compatibility from a successful install.

  • Start Appium with the plugin enabled and confirm the server loads it.
  • Exercise each command the plugin handles, including expected results and error paths.
  • Check whether each handler calls next() in cases where the default behavior or later plugins should continue.
  • Test the Appium releases you claim to support, including any proxy behavior your plugin changes.
  • Document configuration options, side effects and the commands whose behavior the plugin may replace.

These are engineering recommendations, not an Appium-prescribed test matrix. Because plugin code can change server command behavior, test in a controlled environment before enabling it on a server used by others.

Publish, install and manage a distributed plugin

The development guide describes publishing a package through npm and installing it with appium plugin install --source=npm <package>. The current extension CLI also supports git, github and local sources; Git and GitHub installation require the package name. Which route suits a project depends on how its audience accesses releases and how it manages versions; Appium documents the mechanisms, not a universally best distribution choice.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft

Useful extension management commands include:

appium plugin list
appium plugin run <name> <script>
appium plugin update <name>
appium plugin uninstall <name>

The CLI’s update behavior defaults to minor and patch changes. Use --unsafe to permit major updates, which may break compatibility. Check the current syntax and supported options in the Appium extension CLI reference.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Troubleshoot common plugin issues

The plugin installs but does not run

Installation and activation are separate. Start Appium with --use-plugins=example, using the exact registered pluginName.

Appium cannot load the plugin class

Check that main points to the built entry file, the entry file exports the class named by mainClass, and that class extends BasePlugin imported from appium/plugin. Also verify the package includes the built file.

The original command or proxy behavior is missing

Review the handler’s control flow. If the default or next behavior should run, call and await next(); taking over a command without doing so prevents the remaining chain from running.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.

Edits do not appear in a running server

Restart Appium after code changes, or configure APPIUM_RELOAD_EXTENSIONS to request reloading when a new session starts.

The plugin fails on another Appium release

Check the peer dependency range and test against the exact Appium version in use. Compatibility is version-dependent; an Appium 2.0 interface reference does not establish support for every release.

Or skip the browser setup

For website screenshots inside a development workflow, ScreenshotNeo is a separate screenshot API and MCP server; it does not replace an Appium plugin for controlling mobile-app behavior. A single GET request returns a screenshot or PDF. Example cURL request, using the documented API pattern with an example target URL:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo documentation for the API details. It accepts cookie or consent banners before capture and removes more than 60 known consent platforms, newsletter popups and chat widgets; each step can be turned off. Bot checks, blank pages, timeouts, failed loads and cache hits cost nothing, and response headers identify the page verdict and billing status. Its MCP server gives AI agents tools to take screenshots, get page information and capture PDFs.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 screenshots. Sign up for ScreenshotNeo’s free plan.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. Shenzhen desk3 min
    HONOR Expands Beyond Smartphones With Humanoid Robot RevealHONOR said it unveiled its first humanoid robot at MWC 2026 and named shopping assistance, workplace inspections, and supportive companionship as intended uses. Later Robotics D1 claims and a reported…
  2. Cupertino desk5 min
    Apple Unveils AirPods Max 2: The Upgrade That Should Have Happened Years AgoAirPods Max 2 adds H2-powered audio features and Apple claims up to 1.5× more effective ANC, but its design, Smart Case, and 20-hour battery rating are unchanged. Wired lossless audio…
  3. Cupertino desk4 min
    Apple’s OLED Touch MacBooks Are Coming—but the Dynamic Island Is the Real GambleApple has not announced an OLED touchscreen MacBook, but reports point to high-end models arriving in late 2026 or early 2027. The reported Mac Dynamic Island could be useful, but…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.