How can mod_rewrite be used to rewrite URLs in PHP applications?

Mod_rewrite can be used to rewrite URLs in PHP applications by creating rewrite rules in the .htaccess file. This allows for cleaner and more user-friendly URLs, as well as improving SEO by making URLs more readable to search engines.

```php
RewriteEngine on
RewriteRule ^products/([0-9]+)/?$ product.php?id=$1 [NC,L]
```

In this example, the rewrite rule will redirect URLs like /products/123 to product.php?id=123. This can be customized to fit the specific needs of the application.