Convert Figma logo to code with AI

aerokube logoselenoid

Selenium Hub successor running browsers within containers. Scalable, immutable, self hosted Selenium-Grid on any platform with single binary.

2,568
321
2,568
49

Top Related Projects

30,518

A browser automation framework and ecosystem.

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

46,847

Fast, easy and reliable testing for anything that runs in a browser.

88,205

JavaScript API for Chrome and Firefox

18,791

Cross-platform automation framework for all kinds of apps, built on top of the W3C WebDriver protocol

Next-gen browser and mobile automation test framework for Node.js

Quick Overview

Selenoid is an alternative Selenium Hub implementation that runs browsers within Docker containers. It provides a scalable and efficient solution for running Selenium tests in parallel, with support for various browser versions and video recording capabilities.

Pros

  • Easy setup and configuration using Docker
  • Supports multiple browser versions and types (Chrome, Firefox, Opera)
  • Built-in video recording and live browser screen viewing
  • Efficient resource management and fast test execution

Cons

  • Requires Docker knowledge for advanced configuration
  • Limited support for non-Docker environments
  • May require additional setup for certain browser-specific features
  • Documentation could be more comprehensive for complex scenarios

Getting Started

To get started with Selenoid, follow these steps:

  1. Install Docker on your system
  2. Download and run the Selenoid Configuration Manager (CM):
curl -s https://aerokube.com/cm/bash | bash
./cm selenoid start --vnc
./cm selenoid-ui start
  1. Configure your Selenium tests to use the Selenoid endpoint:
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setBrowserName("chrome");
capabilities.setVersion("91.0");
capabilities.setCapability("enableVNC", true);
capabilities.setCapability("enableVideo", true);

RemoteWebDriver driver = new RemoteWebDriver(
    URI.create("http://localhost:4444/wd/hub").toURL(),
    capabilities
);
  1. Run your Selenium tests as usual, and they will be executed using Selenoid

For more detailed configuration and usage instructions, refer to the official Selenoid documentation.

Competitor Comparisons

30,518

A browser automation framework and ecosystem.

Pros of Selenium

  • Widely adopted and supported by a large community
  • Supports multiple programming languages (Java, Python, C#, etc.)
  • Extensive documentation and resources available

Cons of Selenium

  • Can be slower and more resource-intensive
  • Setup and configuration can be complex
  • Requires separate WebDriver installations

Code Comparison

Selenium (Java):

WebDriver driver = new ChromeDriver();
driver.get("https://www.example.com");
WebElement element = driver.findElement(By.id("search"));
element.sendKeys("test");
element.submit();

Selenoid (Go):

caps := map[string]interface{}{
    "browserName": "chrome",
    "enableVNC":   true,
}
driver, _ := remote.NewRemote(caps, "http://selenoid:4444/wd/hub")
driver.Get("https://www.example.com")

Selenoid offers a more lightweight and faster alternative to Selenium, with easier setup and built-in video recording capabilities. It's designed specifically for Selenium-compatible tests and provides better scalability for parallel test execution. However, Selenium remains the more versatile and widely-used option, with broader language support and a larger ecosystem of tools and resources.

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

Pros of Playwright

  • Cross-browser support for Chromium, Firefox, and WebKit
  • Built-in auto-wait functionality for improved test stability
  • Powerful API for modern web automation and testing

Cons of Playwright

  • Steeper learning curve for those familiar with Selenium-based tools
  • Limited support for older browser versions

Code Comparison

Playwright:

const { chromium } = require('playwright');

(async () => {
  const browser = await chromium.launch();
  const page = await browser.newPage();
  await page.goto('https://example.com');
  await browser.close();
})();

Selenoid:

WebDriver driver = new RemoteWebDriver(
    URI.create("http://localhost:4444/wd/hub").toURL(),
    new ChromeOptions()
);
driver.get("https://example.com");
driver.quit();

Key Differences

  • Playwright offers a more modern and feature-rich API for web automation
  • Selenoid focuses on Selenium-compatible tools and provides scalable infrastructure
  • Playwright has built-in support for multiple browsers, while Selenoid relies on browser-specific images
  • Selenoid offers easier scaling and parallel test execution in containerized environments

Use Cases

  • Choose Playwright for modern web application testing with cross-browser support
  • Opt for Selenoid when scaling Selenium-based tests in a containerized infrastructure is a priority
46,847

Fast, easy and reliable testing for anything that runs in a browser.

Pros of Cypress

  • Built-in automatic waiting and retry mechanisms for more stable tests
  • Rich, interactive test runner with time-travel debugging
  • Extensive documentation and active community support

Cons of Cypress

  • Limited cross-browser support (primarily focused on Chrome-based browsers)
  • Cannot interact with multiple browser tabs or windows in a single test
  • Steeper learning curve for developers familiar with Selenium-based frameworks

Code Comparison

Cypress test example:

describe('Login', () => {
  it('should log in successfully', () => {
    cy.visit('/login')
    cy.get('#username').type('user@example.com')
    cy.get('#password').type('password123')
    cy.get('button[type="submit"]').click()
    cy.url().should('include', '/dashboard')
  })
})

Selenoid (with Selenium WebDriver) test example:

@Test
public void loginTest() {
    driver.get("https://example.com/login");
    driver.findElement(By.id("username")).sendKeys("user@example.com");
    driver.findElement(By.id("password")).sendKeys("password123");
    driver.findElement(By.cssSelector("button[type='submit']")).click();
    assertTrue(driver.getCurrentUrl().contains("/dashboard"));
}

While Cypress offers a more modern, developer-friendly approach with built-in assertions and automatic waiting, Selenoid provides greater flexibility in browser choice and parallel test execution. The choice between the two depends on specific project requirements and team preferences.

88,205

JavaScript API for Chrome and Firefox

Pros of Puppeteer

  • Built-in support for modern web features and JavaScript APIs
  • Extensive API for browser automation and scraping
  • Seamless integration with Node.js projects

Cons of Puppeteer

  • Limited to Chromium-based browsers
  • Higher resource consumption compared to headless browsers

Code Comparison

Selenoid (Go):

caps := map[string]interface{}{
    "browserName": "chrome",
    "version":     "75.0",
}
driver, err := remote.NewRemoteWebDriver(hubURL, caps)

Puppeteer (JavaScript):

const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('https://example.com');

Key Differences

  • Selenoid is a powerful Selenium hub implementation, while Puppeteer is a Node.js library for controlling Chromium
  • Selenoid supports multiple browser types and versions, whereas Puppeteer is limited to Chromium-based browsers
  • Puppeteer offers more fine-grained control over browser behavior and page interactions
  • Selenoid is better suited for large-scale, distributed testing environments, while Puppeteer excels in single-instance automation tasks

Use Cases

Selenoid:

  • Cross-browser testing
  • Scalable test infrastructure
  • Integration with existing Selenium-based test suites

Puppeteer:

  • Web scraping and data extraction
  • Generating PDFs from web pages
  • Automating form submission and UI interactions
18,791

Cross-platform automation framework for all kinds of apps, built on top of the W3C WebDriver protocol

Pros of Appium

  • Cross-platform support for mobile testing (iOS, Android) and desktop apps
  • Supports multiple programming languages for test scripts
  • Large community and extensive documentation

Cons of Appium

  • Slower test execution compared to Selenoid
  • More complex setup and configuration process
  • Can be less stable due to dependencies on multiple components

Code Comparison

Appium (JavaScript):

const driver = await wdio.remote({
  capabilities: {
    platformName: 'Android',
    automationName: 'UiAutomator2',
    deviceName: 'emulator-5554',
    app: '/path/to/app.apk'
  }
});

Selenoid (Go):

caps := selenium.Capabilities{
    "browserName": "chrome",
    "selenoid:options": map[string]interface{}{
        "enableVNC": true,
        "enableVideo": true,
    },
}
driver, err := selenium.NewRemote(caps, "http://localhost:4444/wd/hub")

Both Appium and Selenoid are powerful tools for automated testing, but they serve different purposes. Appium excels in mobile app testing and offers broader language support, while Selenoid focuses on efficient browser testing with faster execution times and easier scalability for web applications.

Next-gen browser and mobile automation test framework for Node.js

Pros of WebdriverIO

  • More comprehensive test automation framework with built-in assertion libraries and reporting tools
  • Supports both mobile and web application testing
  • Large and active community with extensive documentation and plugins

Cons of WebdriverIO

  • Steeper learning curve due to its extensive feature set
  • Potentially slower execution compared to Selenoid's lightweight approach
  • May require more setup and configuration for complex test scenarios

Code Comparison

WebdriverIO example:

describe('My Login application', () => {
    it('should login with valid credentials', async () => {
        await browser.url(`https://the-internet.herokuapp.com/login`);
        await $('#username').setValue('tomsmith');
        await $('#password').setValue('SuperSecretPassword!');
        await $('button[type="submit"]').click();
        await expect($('#flash')).toBeExisting();
    });
});

Selenoid example (using Selenium WebDriver):

WebDriver driver = new RemoteWebDriver(new URL("http://localhost:4444/wd/hub"), capabilities);
driver.get("https://the-internet.herokuapp.com/login");
driver.findElement(By.id("username")).sendKeys("tomsmith");
driver.findElement(By.id("password")).sendKeys("SuperSecretPassword!");
driver.findElement(By.cssSelector("button[type='submit']")).click();
Assert.assertTrue(driver.findElement(By.id("flash")).isDisplayed());

Note: Selenoid focuses on providing a scalable Selenium infrastructure, while WebdriverIO is a full-featured test automation framework. The code comparison showcases the different approaches to writing test scripts in each ecosystem.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

Selenoid

Build Status Coverage Go Report Card Release Docker Pulls StackOverflow Tag

Selenoid is a powerful implementation of Selenium hub using Docker containers to launch browsers. Selenoid Animation

Features

One-command Installation

Start browser automation in minutes by downloading Configuration Manager binary and running just one command:

$ ./cm selenoid start --vnc --tmpfs 128

That's it! You can now use Selenoid instead of Selenium server. Specify the following Selenium URL in tests:

http://localhost:4444/wd/hub

Ready to use Browser Images

No need to manually install browsers or dive into WebDriver documentation. Available images: Browsers List

New images are added right after official releases. You can create your custom images with browsers.

Live Browser Screen and Logs

New rich user interface showing browser screen and Selenium session logs: Selenoid UI

Video Recording

  • Any browser session can be saved to H.264 video (example)
  • An API to list, download and delete recorded video files

Convenient Logging

  • Any browser session logs are automatically saved to files - one per session
  • An API to list, download and delete saved log files

Lightweight and Lightning Fast

Suitable for personal usage and in big clusters:

  • Consumes 10 times less memory than Java-based Selenium server under the same load
  • Small 6 Mb binary with no external dependencies (no need to install Java)
  • Browser consumption API working out of the box
  • Ability to send browser logs to centralized log storage (e.g. to the ELK-stack)
  • Fully isolated and reproducible environment

Detailed Documentation and Free Support

Maintained by a growing community:

Complete Guide & Build Instructions

Complete reference guide (including building instructions) can be found at: http://aerokube.com/selenoid/latest/

Selenoid in Kubernetes

Selenoid was initially created to be deployed on hardware servers or virtual machines and is not suitable for Kubernetes. Detailed motivation is described here. If you still need running Selenium tests in Kubernetes, then take a look at Moon - our dedicated solution for Kubernetes.

Known Users

JetBrains Yandex Sberbank Technology ThoughtWorks VK.com SuperJob PropellerAds AlfaBank 3CX IQ Option Mail.Ru Group Newegg.Com Badoo BCS Quality Lab AT Consulting Royal Caribbean International Sixt Testjar Flipdish RiAdvice