What are transients in WordPress, and how are they used?

Transients store temporary data in the database, improving site performance by reducing the need for repetitive queries. Ideal for caching API responses or expensive database operations, they are set with set_transient() and automatically expire after a specified time.