---
title: Frontend Performance Testing | TestingBot Blog
description: With the release of TestingBot's Performance Testing, you can now retrieve
  various performance metrics from Chrome during your Automated Tests.
source_url:
  html: https://testingbot.com/blog/frontend-performance-testing
  md: https://testingbot.com/blog/frontend-performance-testing.md
---

# Performance testing with Selenium

By [Jochen D.](https://testingbot.com/about/jochen-d)2019-02-27

 Share on Facebook 

 Share on Twitter 

 Post on Reddit 

 Share link 

 ![Chrome Devtools](https://testingbot.com/assets/blog/2019/devtools.jpg)

With the release of TestingBot's [Performance Testing](https://testingbot.com/support/web-automate/selenium/performance), you can now retrieve various performance metrics from Chrome during your Automated Tests.

We fetch these various metrics from the Chrome browser via Chrome's Devtools Protocol.

TestingBot has added custom WebDriver commands which you can use to fetch metrics from the Chrome browser during your test, including:

- Pageload Time
- Number of HTTP(s) requests
- domContentLoaded
- firstPaint metrics

With this new feature, you can for example add checks in your Automated tests to verify if the Pageload Time is below a specific threshold.  
If the Pageload Time is too high, the test will fail, alerting you that a performance regression occurred.

Please see our [Frontend Performance Testing Documentation](https://testingbot.com/support/web-automate/selenium/performance) for more details on how to use this feature.

Sample Code:

```ruby
require "rubygems"
require "selenium-webdriver"
require "selenium/client"

caps = {
  :browserName => "chrome",
  :version => "latest",
  :platform => "WIN10",
  :debugging => true
}

urlhub = "https://API_KEY:API_SECRET@hub.testingbot.com/wd/hub"
client = Selenium::WebDriver::Remote::Http::Default.new
client.timeout = 120

@webdriver = Selenium::WebDriver.for :remote, :url => urlhub, :desired_capabilities => caps, :http_client => client

@webdriver.navigate.to "https://testingbot.com/"
performance = @webdriver.execute_script("tb:performance")
assert performance["load"] < 900 # if the pageload time is below 0.9 seconds, fail the test.
@webdriver.quit
```

[← Previous post TestingBot and ScriptWorks integration: Codeless Automated Testing](https://testingbot.com/blog/testingbot-codeless-testing) [Next post → Advanced WebDriver Testing: Intercepting and Mocking Network](https://testingbot.com/blog/webdriver-network-testing)

## Sidebar

### TestingBot Cloud Testing

Run automated, manual and visual tests on remote browsers and devices. Sign up for a free trial.

[Free Trial](https://testingbot.com/users/sign_up)

### Latest articles

[![Announcing AI Test Insights](https://testingbot.com/assets/blog/2026/ai-insights.jpg)](https://testingbot.com/blog/ai-test-insights)

#### Announcing AI Test Insights

Use AI Insights to quickly discover why an automated test...

[Read: Announcing AI Test Insights](https://testingbot.com/blog/ai-test-insights)

[![Selenium vs Playwright 2026](https://testingbot.com/assets/blog/2026/selenium-vs-playwright-2026.jpg)](https://testingbot.com/blog/selenium-vs-playwright)

#### Selenium vs Playwright 2026

Comparing Selenium vs Playwright - which is the best test...

[Read: Selenium vs Playwright 2026](https://testingbot.com/blog/selenium-vs-playwright)

[![Maestro Physical Device Testing](https://testingbot.com/assets/blog/2026/maestro-physical.jpg)](https://testingbot.com/blog/maestro-physical-device-testing)

#### Maestro Physical Device Testing

Maestro testing in parallel on physical Android and iOS d...

[Read: Maestro Physical Device Testing](https://testingbot.com/blog/maestro-physical-device-testing)

## Related Articles

[![Selenium vs Playwright 2026](https://testingbot.com/assets/blog/2026/selenium-vs-playwright-2026.jpg)](https://testingbot.com/blog/selenium-vs-playwright "Selenium vs Playwright 2026")

### [Selenium vs Playwright 2026](https://testingbot.com/blog/selenium-vs-playwright)

Comparing Selenium vs Playwright - which is the best test framework for your usecase?

[Read article →](https://testingbot.com/blog/selenium-vs-playwright)

[![Selenium 20th birthday](https://testingbot.com/assets/blog/2024/selenium20.webp)](https://testingbot.com/blog/selenium-20-years "Selenium 20th birthday")

### [Selenium 20th birthday](https://testingbot.com/blog/selenium-20-years)

Celebrate Selenium's 20th birthday. An overview of the years.

[Read article →](https://testingbot.com/blog/selenium-20-years)

[![ChromeOS Cloud Testing](https://testingbot.com/assets/blog/2025/chromeos.jpg)](https://testingbot.com/blog/chromeos-testing "ChromeOS Cloud Testing")

### [ChromeOS Cloud Testing](https://testingbot.com/blog/chromeos-testing)

ChromeOS Manual and Automated testing in the cloud.

[Read article →](https://testingbot.com/blog/chromeos-testing)

[![Selenium WebDriver BiDi](https://testingbot.com/assets/blog/2024/bidi.webp)](https://testingbot.com/blog/webdriver-bidi "Selenium WebDriver BiDi")

### [Selenium WebDriver BiDi](https://testingbot.com/blog/webdriver-bidi)

WebDriver BiDi support is now available on TestingBot. Learn how to use this exciting new improvement with your Selenium tests.

[Read article →](https://testingbot.com/blog/webdriver-bidi)

## More by Jochen D.

[![Announcing AI Test Insights](https://testingbot.com/assets/blog/2026/ai-insights.jpg)](https://testingbot.com/blog/ai-test-insights "Announcing AI Test Insights")
### [Announcing AI Test Insights](https://testingbot.com/blog/ai-test-insights)

Use AI Insights to quickly discover why an automated test failed.

[![Maestro Physical Device Testing](https://testingbot.com/assets/blog/2026/maestro-physical.jpg)](https://testingbot.com/blog/maestro-physical-device-testing "Maestro Physical Device Testing")
### [Maestro Physical Device Testing](https://testingbot.com/blog/maestro-physical-device-testing)

Maestro testing in parallel on physical Android and iOS devices.

[![tvOS Physical Device Testing](https://testingbot.com/assets/blog/2025/appletv.jpg)](https://testingbot.com/blog/tvos-automated-testing "tvOS Physical Device Testing")
### [tvOS Physical Device Testing](https://testingbot.com/blog/tvos-automated-testing)

Run automated tvOS tests on physical AppleTV devices.

[See all posts by Jochen D. →](https://testingbot.com/about/jochen-d)

## Ready to start testing?
[Start a free trial](https://testingbot.com/users/sign_up)
