Django Check SEO will check the SEO aspects of your site for you, and will provide advice in case of problems.
Project description
Replacing some features of Yoast or SEMrush for django CMS users.
In other words, django-check-seo will tell you if you have problems concerning a broad range of SEO aspects of your pages.
Installation
The following instructions are for an installation on a djangocms-based website using >=python3 & >=django2.
For instruction on how to install django-check-seo on a djangocms-based website that runs on python 2.7
and django 1.8.15
, clic here:
- Install module using pipenv:
pipenv install django-check-seo
- Or pip:
pip install django-check-seo
- Add it to your installed apps:
"django_check_seo",
- Add it to your
urls.py
(beforeurl(r'^', include('cms.urls')),
or it will not work):
url(r"^django-check-seo/", include("django_check_seo.urls")),
- Or add this if you're using path:
path("django-check-seo/", include("django_check_seo.urls")),
Prerequisites
This application need beautifulsoup4
, requests
, djangocms
& djangocms_page_meta
.
Config
Basic settings
Basic config (used by default) is in django-check-seo/conf/settings.py
:
SEO_SETTINGS = {
"content_words_number": [300, 600],
"internal_links": 1,
"external_links": 1,
"meta_title_length": [30, 60],
"meta_description_length": [50, 160],
"keywords_in_first_words": 50,
"max_link_depth": 3,
"max_url_length": 70,
}
If you need to change something, just define it in your mywebsite/settings.py
file in a dict named DJANGO_CHECK_SEO_SETTINGS
.
Example:
If you put this in your settings.py
file:
DJANGO_CHECK_SEO_SETTINGS = {
"internal_links": 25,
"meta_title_length": [15,30],
}
Then this will be the settings used by the application:
SEO_SETTINGS = {
"content_words_number": [300, 600],
"internal_links": 25,
"external_links": 1,
"meta_title_length": [15,30],
"meta_description_length": [50, 160],
"keywords_in_first_words": 50,
"max_link_depth": 3,
"max_url_length": 70,
}
Use http
instead of https
By default, the application will attempt to make requests in https.
To enable plain http queries, you can add a variable named DJANGO_CHECK_SEO_FORCE_HTTP
set to True
in your settings.py.
Example:
# Force HTTP
DJANGO_CHECK_SEO_FORCE_HTTP = True
# Force HTTPS (default case, same as not defining the variable)
DJANGO_CHECK_SEO_FORCE_HTTP = False
Authentication
The website you want to test may require a prior connection due to a .htaccess file (or may use wsgi-basic-auth), which prevents django-check-seo from accessing its html code.
To prevent this, you can specify the login informations (username/password) in the DJANGO_CHECK_SEO_AUTH
dictionnary (in your website settings).
This dictionary must contain two keys named user
and pass
.
Example:
- In
mywebsite/settings.py
:
DJANGO_CHECK_SEO_AUTH = {
"user": os.getenv("HTACCESS_USER"),
"pass": os.getenv("HTACCESS_PASS"),
}
- In
.env
file:
export HTACCESS_USER=myusername
export HTACCESS_PASS=mypassword
WSGI_AUTH_CREDENTIALS=$HTACCESS_USER:$HTACCESS_PASS
Want a screenshot?
Other screenshots and videos are available on the wiki.
Interested in finding out more?
Take a look at the wiki:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for django_check_seo-0.0.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5e645ffe792f64a1068dbd15dbac2e1ec7a68bf3347627edcea03a95c6603587 |
|
MD5 | c544add9d3157efca2f9b545e81b688b |
|
BLAKE2b-256 | 6c33236c468441e7c35d1291c6411ed760ca46cab1983dc1c813fbc79876a12f |