internal error 500 in apache

problem with mod_rewrite and .htaccess with this config:
root page is okay but on the subpage even when there is no route on route file i have
apache internal error 500 and there is no log on the site folder and apache logs.

RewriteEngine On
# Avoid redirecting requests for existing files and directories
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

# Avoid redirecting index.php itself
RewriteCond %{REQUEST_URI} !^/index.php$

# Route all other requests to index.php
RewriteRule ^ index.php [L]

You’re missing RewriteBase / most likely.

Or a subdirectory and RewriteBase /NAME isn’t set, e.g. https://domain.com/foo/page1, https://domain.com/foo/page2 should have RewriteBase /foo set otherwise it applies to top-level.