---
id: "regexp-compile"
kind: "web-feature"
canonical: "https://timetostable.com/feature/regexp-compile"
baseline: "limited"
bcd_version: "8.1.11"
web_features_version: "3.48.0"
---

# RegExp compile() (`regexp-compile`)

The compile() method of RegExp objects recompiles an existing regular expression object using a new pattern and flags.

- **Group**: Regular expressions
- **Baseline**: Limited Availability
- **Specification**: https://tc39.es/ecma262/multipage/additional-ecmascript-features-for-web-browsers.html#sec-regexp.prototype.compile
- **Constituent BCD keys**: 1

## Browser Support Timeline

| Browser | Version | Release Date |
| --- | --- | --- |
| Firefox | 1 | 2004-11-09 |
| Safari | 3.1 | 2008-03-18 |
| Safari on iOS | 2 | 2008-07-11 |
| Chrome | 1 | 2008-12-11 |
| Firefox for Android | 4 | 2011-03-29 |
| Chrome Android | 18 | 2012-06-27 |
| Edge | 12 | 2015-07-29 |

