But a hacker can damage your WordPress site if you are not awake by creating new new WordPress exploit and vulnerability. To protect from this, i have shared some of my codes that will help you.
Protect wp-config.php - wp-config.php contains the configuration of WordPress sites. So it's the best important part of your site and you should be kept safe from the public. For this enter your Cpanel and open .htaccess file then paste following code at the top.
# Codiblog Security <files wp-config.php> Order deny,allow Deny from all </files>
Protect wp-content folder - wp-content folder to collect all kinds of required information like images,css,plugins.themes etc. In many cases, hackers took wp-content folder control and can steal many important information. So you need to determine which contents you want to show in public. For determine enter your Cpanel and open .htaccess file then paste following code at the top.
# Codiblog Security Order deny,allow Deny from all <Files ~ “.(xml|css|jpeg|png|gif|js)$”> Allow from all </Files>That's it for this day. I think that you will like.