crypto
The node:crypto module provides cryptographic functionality that includes a set of wrappers for OpenSSL's hash, HMAC, cipher, decipher, sign, and verify functions.
All node:crypto APIs are fully supported in Workers with the following exceptions:
- The functions generateKeyPair โ and generateKeyPairSync โ do not support DSA or DH key pairs.
 ed448andx448curves are not supported.
The full node:crypto API is documented in the Node.js documentation for node:crypto โ.
The WebCrypto API is also available within Cloudflare Workers. This does not
require the nodejs_compat compatibility flag.
Was this helpful?
- Resources
 - API
 - New to Cloudflare?
 - Products
 - Sponsorships
 - Open Source
 
- Support
 - Help Center
 - System Status
 - Compliance
 - GDPR
 
- Company
 - cloudflare.com
 - Our team
 - Careers
 
- 2025 Cloudflare, Inc.
 - Privacy Policy
 - Terms of Use
 - Report Security Issues
 - Trademark