Введіть назву проєкту та отримайте готові налаштування для бази даних та WordPress.
Наприклад: мій сайт, мій блог (можна кирилицею)
Простий або сильний (16 символів)
Отримайте готові налаштування
Використовуйте кнопки копіювання або експорт у TXT
lifetime_db
lifetime_user
453hs89w5h
lifetime-site
lifetime-admin
123еs87w4x
CREATE DATABASE lifetime_db; CREATE USER 'lifetime_user'@'localhost' IDENTIFIED BY '453hs89w5h'; GRANT ALL PRIVILEGES ON lifetime_db.* TO 'lifetime_user'@'localhost'; FLUSH PRIVILEGES;
/** The name of the database for WordPress */ define( 'DB_NAME', 'lifetime_db' ); /** Database username */ define( 'DB_USER', 'lifetime_user' ); /** Database password */ define( 'DB_PASSWORD', '453hs89w5h' ); /** Database hostname */ define( 'DB_HOST', 'localhost' ); /** Database charset to use in creating database tables. */ define( 'DB_CHARSET', 'utf8mb4' ); /** The database collate type. Don't change this if in doubt. */ define( 'DB_COLLATE', '' );
# Protect wp-config.php
<files wp-config.php>
order allow,deny
deny from all
</files>
# Disable directory browsing
Options -Indexes
# Protect hidden files
RedirectMatch 403 /\..*$
# Block access to sensitive files
<FilesMatch "(^#.*#|\.(php|inc|log|bak|sql|git|svn|htaccess|htpasswd|ini|sh|yml|json|lock|md|txt|dist|editorconfig|gitattributes|gitignore|eslintignore|eslintrc|prettierrc|stylelintrc)$)">
Order allow,deny
Deny from all
</FilesMatch>
# Gzip compression
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/html text/css text/javascript application/javascript application/json
</IfModule>
# Browser caching
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access plus 1 year"
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/gif "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType image/svg+xml "access plus 1 year"
ExpiresByType text/css "access plus 1 month"
ExpiresByType text/javascript "access plus 1 month"
ExpiresByType application/javascript "access plus 1 month"
</IfModule>
# WordPress security headers
<IfModule mod_headers.c>
Header set X-Frame-Options "SAMEORIGIN"
Header set X-Content-Type-Options "nosniff"
Header set X-XSS-Protection "1; mode=block"
Header set Referrer-Policy "strict-origin-when-cross-origin"
</IfModule>
# Allow all bots to crawl the site User-agent: * Allow: / # Disable access to sensitive directories Disallow: /wp-admin/ Disallow: /wp-includes/ Disallow: /wp-content/plugins/ Disallow: /wp-content/themes/ Disallow: /wp-content/uploads/ Disallow: /wp-config.php Disallow: /readme.html Disallow: /license.txt Disallow: /xmlrpc.php Disallow: /wp-signup.php Disallow: /wp-activate.php Disallow: /wp-login.php Disallow: /wp-register.php # Allow access to necessary resources Allow: /wp-admin/admin-ajax.php Allow: /wp-content/uploads/ # Sitemap location (replace with your actual sitemap URL) Sitemap: https://yourdomain.com/sitemap.xml # Crawl delay (optional - helps reduce server load) # Crawl-delay: 1