diff --git a/searx/templates/magi/404.html b/searx/templates/magi/404.html
new file mode 100644
index 000000000..1a10514cc
--- /dev/null
+++ b/searx/templates/magi/404.html
@@ -0,0 +1,9 @@
+{% extends "simple/base.html" %}
+{% block content %}
+
+
{{ _('Page not found') }}
+ {% autoescape false %}
+
{{ _('Go to %(search_page)s.', search_page='{} '.format(url_for('index'), _('search page'))) }}
+ {% endautoescape %}
+
+{% endblock %}
diff --git a/searx/templates/magi/base.html b/searx/templates/magi/base.html
new file mode 100644
index 000000000..0efc5a99c
--- /dev/null
+++ b/searx/templates/magi/base.html
@@ -0,0 +1,84 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ {% block title %}{% endblock %}{{ instance_name }}
+ {% block meta %}{% endblock %}
+ {% if rtl %}
+
+ {% else %}
+
+ {% endif %}
+ {% block styles %}{% endblock %}
+
+
+
+ {% block head %}
+
+ {% endblock %}
+
+
+
+
+
+
+
+
+ {%- from 'simple/icons.html' import icon_big -%}
+
+
+
+
+ {% block header %}
+ {% endblock %}
+ {% block content %}
+ {% endblock %}
+
+
+
+
+
+
+
diff --git a/searx/templates/magi/categories.html b/searx/templates/magi/categories.html
new file mode 100644
index 000000000..1bbcafb25
--- /dev/null
+++ b/searx/templates/magi/categories.html
@@ -0,0 +1,26 @@
+{% from 'simple/icons.html' import icon_big %}
+{%- set category_icons = {
+ 'general': 'search-outline',
+ 'images': 'image-outline',
+ 'videos': 'play-outline',
+ 'news': 'newspaper-outline',
+ 'map': 'location-outline',
+ 'music': 'musical-notes-outline',
+ 'it': 'layers-outline',
+ 'science': 'school-outline',
+ 'files': 'file-tray-full-outline',
+ 'social media': 'people-outline',
+} -%}
+{{- '' -}}
+
+ {%- for category in categories_as_tabs -%}
+
+
+ {{- icon_big(category_icons[category]) if category in category_icons else icon_big('globe-outline') -}}
+ {{- _(category) -}}
+
+
+ {%- endfor -%}
+ {%- if display_tooltip %}
{{ _('Click on the magnifier to perform search') }}
{% endif -%}
+
{{- '' -}}
+
diff --git a/searx/templates/magi/filters/languages.html b/searx/templates/magi/filters/languages.html
new file mode 100644
index 000000000..86f0fce90
--- /dev/null
+++ b/searx/templates/magi/filters/languages.html
@@ -0,0 +1,13 @@
+{{- '' -}}
+ {{ _('Default language') }}
+
+ {{- _('Auto-detect') -}}
+ {%- if current_language == 'auto' %} ({{ search_language }}){%- endif -%}
+
+ {%- for lang_id,lang_name,country_name,english_name,flag in language_codes | sort(attribute=1) -%}
+
+
+ {{- lang_name }} {% if country_name %}({{ country_name }}) {% endif %}
+
+ {%- endfor -%}
+
diff --git a/searx/templates/magi/filters/safesearch.html b/searx/templates/magi/filters/safesearch.html
new file mode 100644
index 000000000..7d2a6b5b7
--- /dev/null
+++ b/searx/templates/magi/filters/safesearch.html
@@ -0,0 +1,5 @@
+
+ {{ _("SafeSearch") + ": " + _('Strict') }}
+ {{ _("SafeSearch") + ": " + _('Moderate') }}
+ {{ _("SafeSearch") + ": " + _('None') }}
+
diff --git a/searx/templates/magi/filters/time_range.html b/searx/templates/magi/filters/time_range.html
new file mode 100644
index 000000000..faf1ab419
--- /dev/null
+++ b/searx/templates/magi/filters/time_range.html
@@ -0,0 +1,17 @@
+{{- '' -}}
+
+ {{- _('Anytime') -}}
+ {{- '' -}}
+
+ {{- _('Last day') -}}
+ {{- '' -}}
+
+ {{- _('Last week') -}}
+ {{- '' -}}
+
+ {{- _('Last month') -}}
+ {{- '' -}}
+
+ {{- _('Last year') -}}
+ {{- '' -}}
+
diff --git a/searx/templates/magi/icons.html b/searx/templates/magi/icons.html
new file mode 100644
index 000000000..7ff4dfc16
--- /dev/null
+++ b/searx/templates/magi/icons.html
@@ -0,0 +1,38 @@
+{# this file was generated by searx/static/themes/simple/gruntfile.js #}
+{%- set icons = {
+ 'warning':' ',
+ 'close':' ',
+ 'chevron-up-outline':' ',
+ 'chevron-right':' ',
+ 'chevron-left':' ',
+ 'menu-outline':' ',
+ 'ellipsis-vertical-outline':' ',
+ 'magnet-outline':' ',
+ 'globe-outline':' ',
+ 'search-outline':' ',
+ 'image-outline':' ',
+ 'play-outline':' ',
+ 'newspaper-outline':' ',
+ 'location-outline':' ',
+ 'musical-notes-outline':' ',
+ 'layers-outline':' ',
+ 'school-outline':' ',
+ 'file-tray-full-outline':' ',
+ 'people-outline':' ',
+ 'heart-outline':' ',
+ 'information-circle-outline':' ',
+
+}
+-%}
+
+{% macro icon(action, alt) -%}
+ {{ icons[action] | replace("ionicon", "ion-icon") | safe }}
+{%- endmacro %}
+
+{% macro icon_small(action) -%}
+ {{ icons[action] | replace("ionicon", "ion-icon-small") | safe }}
+{%- endmacro %}
+
+{% macro icon_big(action, alt) -%}
+ {{ icons[action] | replace("ionicon", "ion-icon-big") | safe }}
+{%- endmacro %}
diff --git a/searx/templates/magi/index.html b/searx/templates/magi/index.html
new file mode 100644
index 000000000..39caed371
--- /dev/null
+++ b/searx/templates/magi/index.html
@@ -0,0 +1,8 @@
+{% extends "simple/base.html" %}
+{% from 'simple/icons.html' import icon_big %}
+{% block content %}
+
+
Search
+ {% include 'simple/simple_search.html' %}
+
+{% endblock %}
diff --git a/searx/templates/magi/info.html b/searx/templates/magi/info.html
new file mode 100644
index 000000000..52b29b0ad
--- /dev/null
+++ b/searx/templates/magi/info.html
@@ -0,0 +1,16 @@
+{% extends 'simple/page_with_header.html' %}
+{% block title %}{{ active_page.title }} - {% endblock %}
+{% block linkto_about %}{% endblock %}
+{% block linkto_donate %}{% endblock %}
+{% block content %}
+
+{% for pagename, locale, page in all_pages %}
+
+ {{page.title}}
+
+{% endfor %}
+
+
+ {{- active_page.html | safe -}}
+
+{% endblock %}
diff --git a/searx/templates/magi/infobox.html b/searx/templates/magi/infobox.html
new file mode 100644
index 000000000..bb9dc8524
--- /dev/null
+++ b/searx/templates/magi/infobox.html
@@ -0,0 +1,50 @@
+
+ {{ infobox.infobox }}
+ {% if infobox.img_src %} {%- endif -%}
+ {{ infobox.content | safe }}
+ {% if infobox.attributes %}
+
+ {% for attribute in infobox.attributes %}
+
+ {{ attribute.label }} :
+ {%- if attribute.image -%}
+
+ {%- else -%}
+ {{ attribute.value }}
+ {%- endif -%}
+
+ {% endfor %}
+
+ {% endif %}
+
+ {% if infobox.urls %}
+
+ {% endif %}
+
+ {% if infobox.relatedTopics %}
+
+ {% endif %}
+
diff --git a/searx/templates/magi/macros.html b/searx/templates/magi/macros.html
new file mode 100644
index 000000000..89ec65e00
--- /dev/null
+++ b/searx/templates/magi/macros.html
@@ -0,0 +1,84 @@
+{% from 'simple/icons.html' import icon_small %}
+
+
+{% macro draw_favicon(favicon) -%}
+
+{%- endmacro %}
+
+{% macro result_open_link(url, classes='') -%}
+
+{%- endmacro %}
+
+{%- macro result_close_link() -%}
+
+{%- endmacro %}
+
+{%- macro result_link(url, title, classes='') -%}
+ {{ result_open_link(url, classes) }}{{ title }}{{ result_close_link() }}
+{%- endmacro -%}
+
+
+{% macro result_header(result, favicons, image_proxify) -%}
+
+ {{- result_open_link(result.url, "url_wrapper") -}}
+ {%- for part in get_pretty_url(result.parsed_url) -%}
+ {{- part -}}
+ {%- endfor %}
+ {{- result_close_link() -}}
+ {%- if result.img_src %}{{ result_open_link(result.url) }} {{ result_close_link() }}{% endif -%}
+ {%- if result.thumbnail %}{{ result_open_link(result.url) }} {{ result_close_link() }}{% endif -%}
+ {{ result_link(result.url, result.title|safe) }}
+{%- endmacro -%}
+
+
+{%- macro result_sub_header(result) -%}
+ {%- if result.publishedDate %}{{ result.publishedDate }} {% endif -%}
+ {%- if result.length %}{{ _('Length') }}: {{ result.length }}
{% endif -%}
+ {%- if result.author %}{{ _('Author') }}: {{ result.author }}
{% endif -%}
+ {%- if result.metadata %}{{ result.metadata|safe }}
{% endif -%}
+{%- endmacro -%}
+
+
+{%- macro result_sub_footer(result, proxify) -%}
+
+
+ {{ result_link(cache_url + result.url, icon_small('ellipsis-vertical-outline') + _('cached'), "cache_link") }} {% if proxify and proxify_results %} {{ result_link(proxify(result.url), icon('link') + _('proxied'), "proxyfied_link") }} {% endif %}
+
{{- '' -}}
+
{{- '' -}}
+{%- endmacro -%}
+
+
+{%- macro result_footer(result) -%}
+
+{%- endmacro -%}
+
+
+{%- macro tabs_open() -%}
+
+{%- endmacro -%}
+
+{%- macro tab_header(name, id, label, checked) -%}
+
+{{ label }}
+
+{%- endmacro -%}
+
+{%- macro tab_footer() -%}
+
+{%- endmacro -%}
+
+{%- macro tabs_close() -%}
+
+{%- endmacro -%}
+
+{%- macro checkbox_onoff(name, checked) -%}
+
+{%- endmacro -%}
+
+{%- macro checkbox(name, checked, disabled) -%}
+{%- if checked == '?' -%}
+ {{- icon_small('warning') -}}
+{%- else -%}
+
+{%- endif -%}
+{%- endmacro -%}
diff --git a/searx/templates/magi/messages/no_cookies.html b/searx/templates/magi/messages/no_cookies.html
new file mode 100644
index 000000000..a9898b4e3
--- /dev/null
+++ b/searx/templates/magi/messages/no_cookies.html
@@ -0,0 +1,5 @@
+{% from 'simple/icons.html' import icon %}
+
+ {{ icon('info-sign') }} {{ _('Information!') }}
+ {{ _('currently, there are no cookies defined.') }}
+
diff --git a/searx/templates/magi/messages/no_results.html b/searx/templates/magi/messages/no_results.html
new file mode 100644
index 000000000..7bb708b8c
--- /dev/null
+++ b/searx/templates/magi/messages/no_results.html
@@ -0,0 +1,23 @@
+{% from 'simple/icons.html' import icon_big %}
+{% if unresponsive_engines %}
+
+ {{ icon_big('warning') }}
+
+
{{ _('Error!') }} {{ _('Engines cannot retrieve results.') }}
+ {% for engine_name, error_type in unresponsive_engines %}
+
{{- '' -}}
+ {{- engine_name }} (
+
+ {{- error_type -}}
+ ){{- '' -}}
+
+ {%- endfor %}
+
{{ _('Please, try again later or find another SearXNG instance.') }} ({{ _('Public instances') }} )
+
+
+{% else %}
+
+
{{ _('Sorry!') }}
+
{{ _("we didn't find any results. Please use another query or search in more categories.") }}
+
+{% endif %}
diff --git a/searx/templates/magi/new_issue.html b/searx/templates/magi/new_issue.html
new file mode 100644
index 000000000..a143cc7df
--- /dev/null
+++ b/searx/templates/magi/new_issue.html
@@ -0,0 +1,75 @@
+{% macro new_issue(engine_name, engine_reliability) %}
+
+{% endmacro %}
diff --git a/searx/templates/magi/opensearch.xml b/searx/templates/magi/opensearch.xml
new file mode 100644
index 000000000..ab423d106
--- /dev/null
+++ b/searx/templates/magi/opensearch.xml
@@ -0,0 +1,21 @@
+
+
+ {{ instance_name }}
+ Search metasearch
+ Search is a metasearch engine that respects your privacy.
+ UTF-8
+ {{ url_for('static', filename='img/favicon.png', _external=True) }}
+ {% if opensearch_method == 'GET' %}
+
+ {% else %}
+
+
+
+ {% endif %}
+ {% if autocomplete %}
+
+ {% endif %}
+
+
+ {{ url_for('search', _external=True) }}
+
diff --git a/searx/templates/magi/opensearch_response_rss.xml b/searx/templates/magi/opensearch_response_rss.xml
new file mode 100644
index 000000000..82d3f7c4e
--- /dev/null
+++ b/searx/templates/magi/opensearch_response_rss.xml
@@ -0,0 +1,53 @@
+
+
+
+ Searx search: {{ q|e }}
+ {{ url_for('search', _external=True) }}?q={{ q|e }}
+ Search results for "{{ q|e }}" - searx
+ {{ number_of_results }}
+ 1
+ {{ number_of_results }}
+
+
+ {% if error_message %}
+ -
+
Error
+ {{ error_message|e }}
+
+ {% endif %}
+ {% for r in results %}
+ -
+
{{ r.title }}
+ {{ r.url }}
+ {{ r.content }}
+ {% if r.pubdate %}{{ r.pubdate }} {% endif %}
+
+ {% endfor %}
+ {% if answers %}
+ {% for a in answers %}
+ -
+
{{ a }}
+ answer
+
+ {% endfor %}
+ {% endif %}
+ {% if corrections %}
+ {% for a in corrections %}
+ -
+
{{ a }}
+ correction
+
+ {% endfor %}
+ {% endif %}
+ {% if suggestions %}
+ {% for a in suggestions %}
+ -
+
{{ a }}
+ suggestion
+
+ {% endfor %}
+ {% endif %}
+
+
diff --git a/searx/templates/magi/page_with_header.html b/searx/templates/magi/page_with_header.html
new file mode 100644
index 000000000..7039f49c1
--- /dev/null
+++ b/searx/templates/magi/page_with_header.html
@@ -0,0 +1,5 @@
+{% set body_class = "page_with_header" %}
+{% extends "simple/base.html" %}
+{% block header %}
+
+{% endblock %}
diff --git a/searx/templates/magi/preferences.html b/searx/templates/magi/preferences.html
new file mode 100644
index 000000000..9626b04d4
--- /dev/null
+++ b/searx/templates/magi/preferences.html
@@ -0,0 +1,441 @@
+{% from 'simple/macros.html' import tabs_open, tabs_close, tab_header, tab_footer, checkbox_onoff, checkbox %}
+{% from 'simple/icons.html' import icon_big %}
+
+{% extends "simple/page_with_header.html" %}
+
+{%- macro plugin_preferences(section) -%}
+{%- for plugin in plugins -%}
+{%- if plugin.preference_section == section -%}
+{{- '' -}}
+ {{ _(plugin.name) }} {{- '' -}}
+
+ {{- checkbox_onoff('plugin_' + plugin.id, plugin.id not in allowed_plugins) -}}
+
{{- '' -}}
+
+ {{- _(plugin.description) -}}
+
{{- '' -}}
+
+{%- endif -%}
+{%- endfor -%}
+{%- endmacro -%}
+
+{% macro engine_about(search_engine) -%}
+{% if search_engine.about is defined %}
+{% set about = search_engine.about %}
+
+{%- endif -%}
+{%- endmacro %}
+
+{%- macro engine_time(engine_name) -%}
+{{- "" -}}
+ {%- if stats[engine_name].time != None -%}
+ {{- stats[engine_name].time -}} {{- "" -}}
+
+ {%- if max_rate95 is not none and max_rate95 > 0 -%}
+
{{- "" -}}
+
{{- "" -}}
+
{{- "" -}}
+
+ {%- endif -%}
+ {{- "" -}}
+ {{- "" -}}
+
{{ _('Median') }}: {{ stats[engine_name].time }}
{{- "" -}}
+
{{ _('P80') }}: {{ stats[engine_name].rate80 }}
{{- "" -}}
+
{{ _('P95') }}: {{ stats[engine_name].rate95 }}
{{- "" -}}
+
+ {%- endif -%}
+
+{%- endmacro -%}
+
+{%- macro engine_reliability(engine_name) -%}
+{% set r = reliabilities.get(engine_name, {}).get('reliablity', None) %}
+{% set checker_result = reliabilities.get(engine_name, {}).get('checker', []) %}
+{% set errors = reliabilities.get(engine_name, {}).get('errors', []) %}
+{% if r != None %}
+ {% if r <= 50 %}{% set label = 'danger' %}
+ {% elif r < 80 %}{% set label = 'warning' %}
+ {% elif r < 90 %}{% set label = '' %}
+ {% else %}{% set label = 'success' %}
+ {% endif %}
+{% else %}
+ {% set r = '' %}
+{% endif %}
+{% if checker_result or errors %}
+{{- "" -}}
+ {{- "" -}}
+
+ {{ icon_big('warning', 'The engine is not reliabled') }} {{ r -}}
+ {{- "" -}}
+ {{- "" -}}
+ {{- "" -}}
+
+{%- else -%}
+{% if r %}{{ r }} {% endif %}
+{%- endif -%}
+{%- endmacro -%}
+
+{% block head %} {% endblock %}
+{% block linkto_preferences %}{% endblock %}
+{% block content %}
+{{ _('Preferences') }}
+
+
+
+{{ tabs_open() }}
+
+ {{ tab_header('maintab', 'general', _('General'), True) }}
+ {% if 'categories' not in locked_preferences %}
+
+ {{ _('Default categories') }}
+ {% set display_tooltip = false %}
+ {% include 'simple/categories.html' %}
+
+ {% endif %}
+ {% if 'language' not in locked_preferences %}
+
+ {{ _('Search language') }}
+ {{- '' -}}
+ {{- '' -}}
+ {{ _('Default language') }}
+ {{ _('Auto-detect') }}
+ {%- for lang_id,lang_name,country_name,english_name,flag in language_codes | sort(attribute=1) -%}
+ {% if flag %}{{ flag }} {% endif%} {{- lang_name }} {% if country_name %}({{ country_name }}) {% endif %}
+ {%- endfor -%}
+ {{- '' -}}
+
+
+ {{- _('What language do you prefer for search?') }} {{ _('Choose Auto-detect to let SearXNG detect the language of your query.') -}}
+
+
+ {% endif %}
+ {% if 'autocomplete' not in locked_preferences %}
+
+ {{ _('Autocomplete') }}
+
+
+ -
+ {%- for backend in autocomplete_backends -%}
+ {{ backend }}
+ {%- endfor -%}
+
+
+ {{ _('Find stuff as you type') }}
+
+ {% endif %}
+ {% if 'safesearch' not in locked_preferences %}
+
+ {{ _('SafeSearch') }}
+
+
+ {{ _('Strict') }}
+ {{ _('Moderate') }}
+ {{ _('None') }}
+
+
+ {{ _('Filter content') }}
+
+ {% endif %}
+ {{ plugin_preferences('general') }}
+ {% if 'doi_resolver' not in locked_preferences %}
+
+ {{ _('Open Access DOI resolver') }}
+
+
+ {%- for doi_resolver_name,doi_resolver_url in doi_resolvers.items() -%}
+
+ {{- doi_resolver_name }} - {{ doi_resolver_url -}}
+
+ {%- endfor -%}
+
+
+
+
+ {% endif %}
+
+ {{ _('Engine tokens') }}
+
+
+
+ {{ _('Access tokens for private engines') }}
+
+ {{ tab_footer() }}
+
+ {{ tab_header('maintab', 'ui', _('User interface')) }}
+ {% if 'locale' not in locked_preferences %}
+
+ {{ _('Interface language') }}
+
+
+ {%- for locale_id,locale_name in locales.items() | sort -%}
+ {{ locale_name }}
+ {%- endfor -%}
+
+
+ {{ _('Change the language of the layout') }}
+
+ {% endif %}
+ {% if 'theme' not in locked_preferences %}
+
+ {{ _('Theme') }}
+
+
+ {%- for name in themes -%}
+ {{ name }}
+ {%- endfor -%}
+
+
+ {{ _('Change SearXNG layout') }}
+
+
+ {{ _('Theme style') }}
+
+
+ {%- for name in ['auto', 'light', 'dark'] -%}
+ {{ _(name) }}
+ {%- endfor -%}
+
+
+ {{ _('Choose auto to follow your browser settings') }}
+
+
+ {{ _('Center Alignment') }}
+
+
+ {{ _('On') }}
+ {{ _('Off')}}
+
+
+ {{ _('Displays results in the center of the page (Oscar layout).') }}
+
+ {% endif %}
+ {% if 'results_on_new_tab' not in locked_preferences %}
+
+ {{ _('Results on new tabs') }}
+
+
+ {{ _('On') }}
+ {{ _('Off')}}
+
+
+ {{_('Open result links on new browser tabs') }}
+
+ {% endif %}
+ {% if 'infinite_scroll' not in locked_preferences %}
+
+ {{ _('Infinite scroll') }}
+
+
+ {{ _('On') }}
+ {{ _('Off')}}
+
+
+ {{ _('Automatically load next page when scrolling to bottom of current page') }}
+
+ {% endif %}
+ {{ plugin_preferences('ui') }}
+ {{ tab_footer() }}
+
+ {{ tab_header('maintab', 'privacy', _('Privacy')) }}
+ {% if 'method' not in locked_preferences %}
+
+ {{ _('HTTP Method') }}
+
+
+ POST
+ GET
+
+
+
+
+ {% endif %}
+ {% if 'image_proxy' not in locked_preferences %}
+
+ {{ _('Image proxy') }}
+
+
+ {{ _('Enabled') }}
+ {{ _('Disabled') }}
+
+
+ {{ _('Proxying image results through SearXNG') }}
+
+ {% endif %}
+ {% if 'query_in_title' not in locked_preferences %}
+
+ {{ _("Query in the page's title") }}
+
+
+ {{ _('Enabled') }}
+ {{ _('Disabled') }}
+
+
+ {{ _("When enabled, the result page's title contains your query. Your browser can record this title") }}
+
+ {% endif %}
+ {{ plugin_preferences('privacy') }}
+ {{ tab_footer() }}
+
+ {{ tab_header('maintab', 'engines', _('Engines')) }}
+ {{ _('Currently used search engines') }}
+ {{ tabs_open() }}
+ {% set ns = namespace(checked=true) %}
+ {% for categ in categories_as_tabs + [OTHER_CATEGORY] %}
+ {{ tab_header('enginetab', 'category' + categ, _(categ), ns.checked )}}
+ {% set ns.checked = false %}
+ {% if categ == OTHER_CATEGORY %}
+ {{_('This tab does not show up for search results, but you can search the engines listed here via bangs.')}}
+ {% endif %}
+
+ {{ tab_footer() }}
+ {% endfor %}
+ {{ tabs_close() }}
+ {{ tab_footer() }}
+
+ {{ tab_header('maintab', 'query', _('Special Queries')) }}
+ {% if answerers %}
+
+ {% endif %}
+ {{ tab_footer() }}
+
+ {{ tab_header('maintab', 'cookies', _('Cookies')) }}
+ {{- "" -}}
+ {{- _('This is the list of cookies and their values SearXNG is storing on your computer.') }} {{- "" -}}
+ {{- _('With that list, you can assess SearXNG transparency.') }} {{- "" -}}
+
+ {% if cookies %}
+
+ {{- "" -}}
+ {{ _('Cookie name') }} {{- "" -}}
+ {{ _('Value') }} {{- "" -}}
+
+ {% for cookie in cookies %}
+ {{- "" -}}
+ {{ cookie }} {{- "" -}}
+ {{ cookies[cookie] }} {{- "" -}}
+
+ {% endfor %}
+
+ {% else %}
+ {% include 'simple/messages/no_cookies.html' %}
+ {% endif %}
+ {{ _('Search URL of the currently saved preferences') }} :
+
+
{{ url_for('index', _external=True) }}?preferences={{ preferences_url_params|e }}{% raw %}&q=%s{% endraw %}
+
+ {{ _('Note: specifying custom settings in the search URL can reduce privacy by leaking data to the clicked result sites.') }}
+ {{ _('URL to restore your preferences in another browser') }} :
+
+
{{ url_for('preferences', _external=True) }}?preferences={{ preferences_url_params|e }}&save=1
+
+ {{ _('Specifying custom settings in the preferences URL can be used to sync preferences across devices.') }}
+ {{ tab_footer() }}
+
+{{ tabs_close() }}
+
+ {{ _('These settings are stored in your cookies, this allows us not to store this data about you.') }}
+
+ {{ _("These cookies serve your sole convenience, we don't use these cookies to track you.") }}
+
+
+
+
+
+
+
+{% endblock %}
diff --git a/searx/templates/magi/result_templates/code.html b/searx/templates/magi/result_templates/code.html
new file mode 100644
index 000000000..3fe429caa
--- /dev/null
+++ b/searx/templates/magi/result_templates/code.html
@@ -0,0 +1,13 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer with context %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+{{- result_sub_header(result) -}}
+{%- if result.content %}{{ result.content|safe }}{% endif %}
+{%- if result.repository -%}
+{{ result.repository }}
+{%- endif -%}
+
+ {{- result.codelines|code_highlighter(result.code_language)|safe -}}
+
{{- '' -}}
+{{- result_sub_footer(result, proxify) -}}
+{{ result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/default.html b/searx/templates/magi/result_templates/default.html
new file mode 100644
index 000000000..263c19a36
--- /dev/null
+++ b/searx/templates/magi/result_templates/default.html
@@ -0,0 +1,28 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer with context %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+{{- result_sub_header(result) -}}
+{% if result.iframe_src -%}
+{{ icon('music-note') }} {{ _('show media') }}
+{%- endif %}
+{%- if result.content %}
+
+ {{ result.content|safe }}
+
+{%- else %}
+
+ {{ _('This site did not provide any description.')|safe }}
+
+{% endif -%}
+{{- result_sub_footer(result, proxify) -}}
+{% if result.iframe_src -%}
+
+
+
+{%- endif %}
+{% if result.audio_src -%}
+
+{%- endif %}
+{{- result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/images.html b/searx/templates/magi/result_templates/images.html
new file mode 100644
index 000000000..8aadbd204
--- /dev/null
+++ b/searx/templates/magi/result_templates/images.html
@@ -0,0 +1,25 @@
+{{- "" -}}
+ {{- "" -}}
+ {{- "" -}}
+ {{ result.title|striptags }} {{- "" -}}
+ {{ result.parsed_url.netloc }} {{- "" -}}
+ {{- "" -}}
+ {{- "" -}}
+
{{ icon('close') }} {{- "" -}}
+
{{ icon('chevron-left') }} {{- "" -}}
+
{{ icon('chevron-right') }} {{- "" -}}
+
+ {{- "" -}}
+ {{- "" -}}
+
{{- "" -}}
+
{{ result.title|striptags }} {{- "" -}}
+
{%- if result.content %}{{ result.content|striptags }}{% else %} {% endif -%}
{{- "" -}}
+
{{- "" -}}
+
{%- if result.author %}{{ _('Author') }}: {{ result.author|striptags }}{% else %} {% endif -%}
{{- "" -}}
+
{%- if result.img_format %}{{ _('Format') }}: {{ result.img_format }}{% else %} {% endif -%}
{{- "" -}}
+
{%- if result.source %}{{ _('Source') }}: {{ result.source }}{% else %} {% endif -%}
{{- "" -}}
+
{{ _('Engine') }}: {{ result.engine }}
{{- "" -}}{{- "" -}}
+
{{ _('View source') }}: {{ result.url }}
{{- "" -}}
+
{{- "" -}}
+
{{- "" -}}
+
diff --git a/searx/templates/magi/result_templates/key-value.html b/searx/templates/magi/result_templates/key-value.html
new file mode 100644
index 000000000..5c4216862
--- /dev/null
+++ b/searx/templates/magi/result_templates/key-value.html
@@ -0,0 +1,12 @@
+
+ {% for key, value in result.items() %}
+ {% if key in ['engine', 'engines', 'template', 'score', 'category', 'positions', 'pretty_url', 'parsed_url'] %}
+ {% continue %}
+ {% endif %}
+
+ {{ key|upper }} : {{ value }}
+
+ {% endfor %}
+
+
+
{{- '' -}}
diff --git a/searx/templates/magi/result_templates/map.html b/searx/templates/magi/result_templates/map.html
new file mode 100644
index 000000000..3bdc378d6
--- /dev/null
+++ b/searx/templates/magi/result_templates/map.html
@@ -0,0 +1,52 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer with context %}
+{% from 'simple/icons.html' import icon_small %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+{{- result_sub_header(result) -}}
+
+{%- if result.content %}{{ result.content|safe }}
{% endif -%}
+
+
+ {%- if result.address -%}
+
+ {{ result.address_label or _('address') }}
+
+ {%- if result.address.name -%}
+ {{ result.address.name }}
+ {%- endif -%}
+ {% if result.address.road -%}
+
+ {%- if result.address.house_number -%}{{- result.address.house_number -}}, {% endif %}
+ {{- result.address.road -}}
+
+ {%- endif %}
+ {%- if result.address.locality -%}
+ {{- result.address.locality -}}
+ {%- if result.address.postcode -%}, {{- result.address.postcode -}} {% endif %}
+
+ {%- endif -%}
+ {%- if result.address.country -%}
+ {{- result.address.country -}}
+ {%- endif -%}
+
+
+ {%- endif %}
+ {%- for info in result.data -%}
+ {{ info.label }} {{ info.value|safe }}
+ {%- endfor -%}
+ {%- for link in result.links -%}
+ {{ link.label }} {{ link.url_label|safe }}
+ {%- endfor -%}
+
+
+{%- if (result.latitude and result.longitude) or result.boundingbox -%}
+ {{ icon_small( 'globe-outline') }} {{ _('show map') }}
+{%- endif -%}
+
+{{- result_sub_footer(result, proxify) -}}
+
+{% if (result.latitude and result.longitude) or result.boundingbox -%}
+
+{%- endif %}
+
+{{- result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/paper.html b/searx/templates/magi/result_templates/paper.html
new file mode 100644
index 000000000..dd610b903
--- /dev/null
+++ b/searx/templates/magi/result_templates/paper.html
@@ -0,0 +1,38 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer, result_link with context %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+
+ {%- if result.publishedDate %}
{{ _("Published date") }}: {{ result.publishedDate }}
{% endif -%}
+ {%- if result.authors %}
{{ _("Author") }}: {{ result.authors | join(", ") }}
{% endif -%}
+ {%- if result.journal -%}
+
+ {{- _("Journal") }}: {{ result.journal -}}
+ {%- if result.volume -%}
+ {{- result.volume -}}
+ {%- if result.number -%}
+ .{{- result.number -}}
+ {%- endif -%}
+ {%- endif -%}
+ {%- if result.pages -%}
+ {{- result.pages -}}
+ {%- endif -%}
+
+
+ {%- endif %}
+ {%- if result.editor %}
{{ _("Editor") }}: {{ result.editor }}
{% endif -%}
+ {%- if result.publisher %}
{{ _("Publisher") }}: {{ result.publisher }}
{% endif -%}
+ {%- if result.type %}
{{ _("Type") }}: {{ result.type }}
{% endif -%}
+ {%- if result.tags %}
{{ _("Tags") }}: {{ result.tags | join(", ")}}
{%- endif -%}
+ {%- if result.doi %}
{{ _("DOI") }}: {{ result_link(doi_resolver + result.doi, result.doi) }}
{% endif -%}
+ {%- if result.issn %}
{{ _("ISSN") }}: {{ result.issn | join(", ") }}
{% endif -%}
+ {%- if result.isbn %}
{{ _("ISBN") }}: {{ result.isbn | join(", ") }}
{% endif -%}
+
+{%- if result.content -%}{{- result.content | safe -}}
{%- endif -%}
+{%- if result.comments -%}{%- endif -%}
+
+ {%- if result.pdf_url -%}{{ result_link(result.pdf_url, _('PDF')) }}{%- endif -%}
+ {%- if result.html_url -%}{{ result_link(result.html_url, _('HTML')) }}{%- endif -%}
+ {%- if result.doi %}{{ result_link('https://www.altmetric.com/details/doi/' + result.doi, 'Altmetric') }}{% endif -%}
+
+{{- result_sub_footer(result, proxify) -}}
+{{- result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/products.html b/searx/templates/magi/result_templates/products.html
new file mode 100644
index 000000000..0a9bbf03a
--- /dev/null
+++ b/searx/templates/magi/result_templates/products.html
@@ -0,0 +1,14 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer with context %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+{{- result_sub_header(result) -}}
+{% if result.price %}{{ result.price }}
{% endif %}
+{% if result.shipping %}{{ result.shipping }}
{% endif %}
+{% if result.source_country %}{{ result.source_country }}
{% endif %}
+{%- if result.content %}
+
+ {{ result.content }}
+
+{% endif -%}
+{{- result_sub_footer(result, proxify) -}}
+{{- result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/torrent.html b/searx/templates/magi/result_templates/torrent.html
new file mode 100644
index 000000000..46cde2a65
--- /dev/null
+++ b/searx/templates/magi/result_templates/torrent.html
@@ -0,0 +1,24 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer, result_link with context %}
+
+{{ result_header(result, favicons, image_proxify) -}}
+{{- result_sub_header(result) -}}
+
+{% if result.magnetlink %} • {{ result_link(result.magnetlink, icon_big('magnet-outline') + _('magnet link'), "magnetlink") }}
{% endif %}
+{% if result.torrentfile %} • {{ result_link(result.torrentfile, icon_big('download-alt') + _('torrent file'), "torrentfile") }}
{% endif %}
+
+{% if result.seed is defined %} • {{ icon_big('arrow-swap') }} {{ _('Seeder') }} {{ result.seed }} • {{ _('Leecher') }} {{ result.leech }}
{% endif %}
+
+{%- if result.filesize %}{{ icon_big('floppy-disk') }} {{ _('Filesize') }}
+ {%- if result.filesize < 1024 %}{{ result.filesize }} {{ _('Bytes') }}
+ {%- elif result.filesize < 1024*1024 %}{{ '{0:0.2f}'.format(result.filesize/1024) }} {{ _('kiB') }}
+ {%- elif result.filesize < 1024*1024*1024 %}{{ '{0:0.2f}'.format(result.filesize/1024/1024) }} {{ _('MiB') }}
+ {%- elif result.filesize < 1024*1024*1024*1024 %}{{ '{0:0.2f}'.format(result.filesize/1024/1024/1024) }} {{ _('GiB') }}
+ {%- else %}{{ '{0:0.2f}'.format(result.filesize/1024/1024/1024/1024) }} {{ _('TiB') }}{% endif -%}
+
+{%- endif -%}
+
+{%- if result.files %}{{ icon_big('file') }} {{ _('Number of Files') }} {{ result.files }}
{% endif -%}
+
+{%- if result.content %}{{ result.content|safe }}
{% endif -%}
+{{- result_sub_footer(result, proxify) -}}
+{{- result_footer(result) }}
diff --git a/searx/templates/magi/result_templates/videos.html b/searx/templates/magi/result_templates/videos.html
new file mode 100644
index 000000000..969f87a4d
--- /dev/null
+++ b/searx/templates/magi/result_templates/videos.html
@@ -0,0 +1,24 @@
+{% from 'simple/macros.html' import result_header, result_sub_header, result_sub_footer, result_footer with context %}
+
+{{ result_header(result, favicons, image_proxify) }}
+{{ result_sub_header(result) }}
+{% if result.iframe_src -%}
+ {{ icon('film-outline') }} {{ _('show video') }}
+{%- endif %}
+{%- if result.content %}
+
+ {{ result.content|safe }}
+
+{%- else %}
+
+ {{ _('This site did not provide any description.')|safe }}
+
+{% endif -%}
+
+{{- result_sub_footer(result, proxify) -}}
+{% if result.iframe_src -%}
+
+
+
+{%- endif %}
+{{ result_footer(result) }}
diff --git a/searx/templates/magi/results.html b/searx/templates/magi/results.html
new file mode 100644
index 000000000..f5d9a6227
--- /dev/null
+++ b/searx/templates/magi/results.html
@@ -0,0 +1,222 @@
+{% extends "simple/base.html" %}
+{% from 'simple/icons.html' import icon, icon_big, icon_small %}
+{% macro engine_data_form(engine_data) -%}
+ {% for engine_name, kv_data in engine_data.items() %}
+ {% for k, v in kv_data.items() %}
+
+ {% endfor %}
+ {% endfor %}
+{%- endmacro %}
+{% block title %}{% if query_in_title %}{{- q|e }} - {% endif %}{% endblock %}
+{% block meta %} {% endblock %}
+{% block content %}
+{% include 'simple/search.html' %}
+
+{% if results and results|map(attribute='template')|unique|list|count == 1 %}
+ {% set only_template = 'only_template_' + results[0]['template']|default('default')|replace('.html', '') %}
+{% else %}
+ {% set only_template = '' %}
+{% endif %}
+
+
+ {% if answers -%}
+
{{ _('Answers') }} :
+ {%- for answer in answers.values() -%}
+
+ {%- endfor -%}
+
+ {%- endif %}
+
+
+
+ {% if corrections %}
+
+
{{ _('Try searching for:') }}
+ {% for correction in corrections %}
+
+
+ {% for category in selected_categories %}
+
+ {% endfor %}
+
+
+
+
+
+ {% if timeout_limit %} {% endif %}
+
+
+
+ {% endfor %}
+
+ {% endif %}
+
+
+ {% for result in results %}
+ {% if result.open_group and not only_template %}
{% endif %}
+ {% set index = loop.index %}
+ {% include get_result_template('simple', result['template']) %}
+ {% if result.close_group and not only_template %}
{% endif %}
+ {% endfor %}
+ {% if not results and not answers %}
+ {% include 'simple/messages/no_results.html' %}
+ {% endif %}
+
+
+ {% if paging %}
+
+ {% endif %}
+
+{% endblock %}
diff --git a/searx/templates/magi/search.html b/searx/templates/magi/search.html
new file mode 100644
index 000000000..9fb4f6f5b
--- /dev/null
+++ b/searx/templates/magi/search.html
@@ -0,0 +1,24 @@
+
+
+
+ {% include 'simple/filters/languages.html' %}
+ {% include 'simple/filters/time_range.html' %}
+ {% include 'simple/filters/safesearch.html' %}
+
+
+ {% if timeout_limit %} {% endif %}
+
diff --git a/searx/templates/magi/searxng-wordmark.min.svg b/searx/templates/magi/searxng-wordmark.min.svg
new file mode 100644
index 000000000..2c316d789
--- /dev/null
+++ b/searx/templates/magi/searxng-wordmark.min.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/searx/templates/magi/simple_search.html b/searx/templates/magi/simple_search.html
new file mode 100644
index 000000000..30a6c2add
--- /dev/null
+++ b/searx/templates/magi/simple_search.html
@@ -0,0 +1,19 @@
+
+
+ {% for category in selected_categories %}
+
+ {% endfor %}
+
+
+
+
+ {% if timeout_limit %} {% endif %}
+
diff --git a/searx/templates/magi/stats.html b/searx/templates/magi/stats.html
new file mode 100644
index 000000000..d2d5ae2b1
--- /dev/null
+++ b/searx/templates/magi/stats.html
@@ -0,0 +1,148 @@
+{% from 'simple/icons.html' import icon_big %}
+{% from 'simple/new_issue.html' import new_issue with context %}
+
+{% extends "simple/page_with_header.html" %}
+
+{%- macro th_sort(column_order, column_name) -%}
+ {% if selected_engine_name %}
+ {{ column_name }}
+ {% elif column_order==sort_order %}
+ {{ column_name }} {{ icon_big('arrow-dropdown') }}
+ {% else %}
+ {{ column_name }}
+ {% endif %}
+{%- endmacro -%}
+
+{% block head %} {% endblock %}
+{% block content %}
+
+
+{% if not engine_stats.get('time') %}
+{{ _('There is currently no data available. ') }}
+{% else %}
+
+
+ {{ th_sort('name', _("Engine name")) }}
+ {{ th_sort('score', _('Scores')) }}
+ {{ th_sort('result_count', _('Result count')) }}
+ {{ th_sort('time', _('Response time')) }}
+ {{ th_sort('reliability', _('Reliability')) }}
+
+ {% for engine_stat in engine_stats.get('time', []) %}
+
+ {{ engine_stat.name }}
+
+ {% if engine_stat.score %}
+ {{ engine_stat.score_per_result|round(1) }}
+ {% endif %}
+
+
+ {%- if engine_stat.result_count -%}
+
+ {{- engine_stat.result_count | int -}}
{{- "" -}}
+
+ {%- endif -%}
+
+
+ {%- if engine_stat.total is not none -%}
+ {{- engine_stat.total | round(1) -}}
{{- "" -}}
+
+ {% if engine_stat.http is not none and engine_stats.max_time %}
{%- endif -%}
+ {% if engine_stat.processing is not none and engine_stats.max_time %}
{%- endif -%}
+
+
+ {%- endif -%}
+
+ {{ engine_reliabilities.get(engine_stat.name, {}).get('reliablity') }}
+
+ {% endfor %}
+
+{% endif %}
+
+{% if selected_engine_name %}
+
+ {% for secondary in [False, True] %}
+ {% set ns = namespace(first=true) %}
+ {% for error in engine_reliabilities[selected_engine_name].errors %}
+ {% if secondary == error.secondary %}
+ {% if ns.first %}
+ {% set ns.first = false %}
+
{% if secondary %}{{ _('Warnings') }}{% else %}{{ _('Errors and exceptions') }}{% endif %}
+ {% endif %}
+
+
+
+ {%- if error.exception_classname -%}
+ {{ _('Exception') }} {{ error.exception_classname }}
+ {%- elif error.log_message -%}
+ {{ _('Message') }} {{ error.log_message }}
+ {%- endif -%}
+ {{ _('Percentage') }} {{ error.percentage }}
+
+ {% if error.log_parameters and error.log_parameters != (None, None, None) %}{{ _('Parameter') }} {{- '' -}}
+
+ {%- for param in error.log_parameters -%}
+ {{ param }}
+ {%- endfor -%}
+
+
+ {% endif %}
+ {{ _('Filename') }} {{ error.filename }}:{{ error.line_no }}
+ {{ _('Function') }} {{ error.function }}
+ {{ _('Code') }} {{ error.code }}
+
+
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
+ {% if engine_reliabilities[selected_engine_name].checker %}
+
{{ _('Checker') }}
+
+
+ {{ _('Failed test') }}
+ {{ _('Comment(s)') }}
+
+ {% for test_name, results in engine_reliabilities[selected_engine_name].checker.items() %}
+
+ {{ test_name }}
+
+ {% for r in results %}{{ r }}
{% endfor %}
+
+
+ {% endfor %}
+
+ {% endif %}
+ {{ new_issue(selected_engine_name, engine_reliabilities[selected_engine_name]) }}
+
+{% endif %}
+
+{% endblock %}
diff --git a/searx/webapp.py b/searx/webapp.py
index deb00dce4..32b39939e 100755
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -924,7 +924,7 @@ button.btn_more {
-
+
-
+