facelessuser: @gir-bot lgtm
diff --git a/docs/src/markdown/about/changelog.md b/docs/src/markdown/about/changelog.md
index 4e6fe523..3af67be7 100644
--- a/docs/src/markdown/about/changelog.md
+++ b/docs/src/markdown/about/changelog.md
@@ -2,6 +2,8 @@
 
 ## 7.2
 
+- **NEW**: Highlight: add new option `language_prefix` which controls the prefix applied to language classes when
+  Pygments is not being used.
 - **NEW**: Add new extension called SaneHeaders which restricts hash headers to only evaluate if the hashes (`#`) are
   followed by a space. Allows extensions like MagicLink to have issues links at the start of a line.
 - **NEW**: Highlight option `linenums` now defaults to `None` and accepts `None`, `True`, or `False`. `None` is
diff --git a/docs/src/markdown/extensions/highlight.md b/docs/src/markdown/extensions/highlight.md
index 74cc59f2..c1a7cf6b 100644
--- a/docs/src/markdown/extensions/highlight.md
+++ b/docs/src/markdown/extensions/highlight.md
@@ -106,6 +106,7 @@ Option                    | Type   | Default               | Description
 `linenums_class`          | string | `#!py3 'linenums'`    | Controls the name of the line number class when Pygments is not used.
 `extend_pygments_lang`    | list   | `#!py3 []`            | A list of extended languages to add.  See [Extended Pygments Lexer Options](#extended-pygments-lexer-options) for more info.
 `legacy_no_wrap_code`     | bool   | `#!py3 False`         | A temporary option provided during the transition period to the new output format. From now on, all block code under `pre` elements will be wrapped in a `code` element as well under Pygments 2.4+. This disables this format. This option will be removed in the future.
+`language_prefix`         | string | `#!py3 'language-'`   | Controls the prefix applied to the language class when Pygments is not used. By default, uses the HTML5 `language-`.
 
 !!! new "New 6.2"
     `legacy_no_wrap_code` was added in `6.3`, but is only provided to help transition to the format when using Pygments 2.4+. This option will be removed in the future.
diff --git a/pymdownx/highlight.py b/pymdownx/highlight.py
index aff651c4..1bcc021b 100644
--- a/pymdownx/highlight.py
+++ b/pymdownx/highlight.py
@@ -88,6 +88,10 @@ DEFAULT_CONFIG = {
         False,
         'Do not wrap block code under pre elements with code elements - Default: False'
     ],
+    'language_prefix': [
+        'language-',
+        'Controls the language prefix for non-Pygments code blocks. - Defaults: "language-"'
+    ],
     '_enabled': [
         True,
         'Used internally to communicate if extension has been explicitly enabled - Default: False'
@@ -184,7 +188,7 @@ class Highlight(object):
     def __init__(
         self, guess_lang=True, pygments_style='default', use_pygments=True,
         noclasses=False, extend_pygments_lang=None, linenums=None, linenums_special=-1,
-        linenums_style='table', linenums_class='linenums', wrapcode=True
+        linenums_style='table', linenums_class='linenums', wrapcode=True, language_prefix='language-'
     ):
         """Initialize."""
 
@@ -197,6 +201,7 @@ class Highlight(object):
         self.linenums_special = linenums_special
         self.linenums_class = linenums_class
         self.wrapcode = wrapcode
+        self.language_prefix = language_prefix
 
         if extend_pygments_lang is None:  # pragma: no cover
             extend_pygments_lang = []
@@ -305,7 +310,7 @@ class Highlight(object):
             code = self.escape(src)
             classes = class_names + ([css_class] if css_class else [])
             if language:
-                classes.append('language-%s' % language)
+                classes.append(self.language_prefix + language)
             class_str = ''
             if len(classes):
                 class_str = ' '.join(classes)
@@ -314,7 +319,7 @@ class Highlight(object):
             classes = class_names
             linenums = self.linenums_style if linenums_enabled else False
             if language:
-                classes.append('language-%s' % language)
+                classes.append(self.language_prefix + language)
             class_str = ''
             if linenums:
                 classes.append(self.linenums_class)
@@ -364,7 +369,8 @@ class HighlightTreeprocessor(Treeprocessor):
                     linenums_special=self.config['linenums_special'],
                     linenums_class=self.config['linenums_class'],
                     extend_pygments_lang=self.config['extend_pygments_lang'],
-                    wrapcode=not self.config['legacy_no_wrap_code']
+                    wrapcode=not self.config['legacy_no_wrap_code'],
+                    language_prefix=self.config['language_prefix']
                 )
                 placeholder = self.md.htmlStash.store(
                     code.highlight(
diff --git a/pymdownx/inlinehilite.py b/pymdownx/inlinehilite.py
index 6ba319d9..ba76e919 100644
--- a/pymdownx/inlinehilite.py
+++ b/pymdownx/inlinehilite.py
@@ -126,6 +126,7 @@ class InlineHilitePattern(InlineProcessor):
             self.pygments_style = config['pygments_style']
             self.use_pygments = config['use_pygments']
             self.noclasses = config['noclasses']
+            self.language_prefix = config['language_prefix']
 
     def highlight_code(self, src, language, classname=None, md=None):
         """Syntax highlight the inline code block."""
@@ -138,7 +139,8 @@ class InlineHilitePattern(InlineProcessor):
                 pygments_style=self.pygments_style,
                 use_pygments=self.use_pygments,
                 noclasses=self.noclasses,
-                extend_pygments_lang=self.extend_pygments_lang
+                extend_pygments_lang=self.extend_pygments_lang,
+                language_prefix=self.language_prefix
             ).highlight(src, language, self.css_class, inline=True)
             el.text = self.md.htmlStash.store(el.text)
         else:
diff --git a/pymdownx/superfences.py b/pymdownx/superfences.py
index 9e8cd2c2..0a63dbc7 100644
--- a/pymdownx/superfences.py
+++ b/pymdownx/superfences.py
@@ -441,6 +441,7 @@ class SuperFencesBlockPreprocessor(Preprocessor):
             self.linenums_class = config.get('linenums_class', 'linenums')
             self.linenums_special = config.get('linenums_special', -1)
             self.wrapcode = not config.get('legacy_no_wrap_code', False)
+            self.language_prefix = config.get('language_prefix', 'language-')
 
     def clear(self):
         """Reset the class variables."""
@@ -795,7 +796,8 @@ class SuperFencesBlockPreprocessor(Preprocessor):
             linenums_special=self.linenums_special,
             linenums_class=self.linenums_class,
             extend_pygments_lang=self.extend_pygments_lang,
-            wrapcode=self.wrapcode
+            wrapcode=self.wrapcode,
+            language_prefix=self.language_prefix
         ).highlight(
             src,
             language,

remove "language" from css class
Hi, 

Question relating to 'pymdownx.highlight':

Is there a way to remove the prefix string "language" in "language-mylanguage"?

I can set `css_class:''`, but I see no option to set the prefix instead of `prefix:'language-'` to `prefix:''`

Highlight.js does support class='mylanguage', without the need to specify class='language-mylanguage'

Thanks
diff --git a/tests/test_extensions/test_highlight.py b/tests/test_extensions/test_highlight.py
index 1f39be50..bc15383b 100644
--- a/tests/test_extensions/test_highlight.py
+++ b/tests/test_extensions/test_highlight.py
@@ -127,6 +127,43 @@ class TestNoClassNoPygments(util.MdCase):
         )
 
 
+class TestCustomLangPrefixNoPygments(util.MdCase):
+    """Test custom language prefix."""
+
+    extension = ['pymdownx.highlight', 'pymdownx.superfences', 'pymdownx.inlinehilite']
+    extension_configs = {
+        'pymdownx.highlight': {
+            'language_prefix': 'lang-',
+            'use_pygments': False
+        }
+    }
+
+    def test_custom_prefix_no_pygments(self):
+        """Test with custom prefix and no Pygments."""
+
+        self.check_markdown(
+            r'''
+            ```python
+            import test
+            test.test()
+            ```
+            ''',
+            r'''
+            <pre class="highlight"><code class="lang-python">import test
+            test.test()</code></pre>
+            ''',  # noqa: E501
+            True
+        )
+
+    def test_custom_prefix_no_pygments_inline(self):
+        """Test with custom prefix and no Pygments with inline code."""
+
+        self.check_markdown(
+            '`#!python import test`',
+            '<p><code class="highlight lang-python">import test</code></p>'
+        )
+
+
 class TestNoPygments(util.MdCase):
     """Test no Pygments."""
 

pip install --editable .
parse_log_pytest
requirements.txt
pytest pytest-cov
3.7
requirements/project.txt requirements/test.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
certifi @ file:///croot/certifi_1671487769961/work/certifi
coverage==7.2.7
exceptiongroup==1.2.2
importlib-metadata==6.7.0
iniconfig==2.0.0
Markdown==3.4.4
packaging==24.0
pluggy==1.2.0
-e git+https://github.com/facelessuser/pymdown-extensions.git@73bd554cf1c927e03d97be382597554d06db67ca#egg=pymdown_extensions
pytest==7.4.4
pytest-cov==4.1.0
PyYAML==6.0.1
tomli==2.0.1
typing_extensions==4.7.1
zipp==3.15.0

name: pymdown-extensions
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2022.12.7=py37h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=22.3.1=py37h06a4308_0
  - python=3.7.16=h7a1cb2a_0
  - readline=8.2=h5eee18b_0
  - setuptools=65.6.3=py37h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.38.4=py37h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - coverage==7.2.7
      - exceptiongroup==1.2.2
      - importlib-metadata==6.7.0
      - iniconfig==2.0.0
      - markdown==3.4.4
      - packaging==24.0
      - pluggy==1.2.0
      - pytest==7.4.4
      - pytest-cov==4.1.0
      - pyyaml==6.0.1
      - tomli==2.0.1
      - typing-extensions==4.7.1
      - zipp==3.15.0
prefix: /opt/conda/envs/pymdown-extensions

tests/test_extensions/test_highlight.py::TestCustomLangPrefixNoPygments::test_custom_prefix_no_pygments tests/test_extensions/test_highlight.py::TestCustomLangPrefixNoPygments::test_custom_prefix_no_pygments_inline
tests/test_extensions/test_highlight.py::TestHighlightInline::test_pymdownx_inline tests/test_extensions/test_highlight.py::TestNoClass::test_no_class tests/test_extensions/test_highlight.py::TestNoClass::test_no_class_and_user_class tests/test_extensions/test_highlight.py::TestNoClass::test_no_class_and_user_class_linenums tests/test_extensions/test_highlight.py::TestNoPygmentsCustomLineClass::test_no_pygments_linenums_custom_class tests/test_extensions/test_highlight.py::TestHighlightSpecial::test_special tests/test_extensions/test_highlight.py::TestHighlightSpecial::test_special_override tests/test_extensions/test_highlight.py::TestDisabledLinenums::test_global_disable
tests/test_extensions/test_highlight.py::TestNoClassNoPygments::test_no_class_no_pygments tests/test_extensions/test_highlight.py::TestNoPygments::test_no_pygments tests/test_extensions/test_highlight.py::TestNoPygments::test_no_pygments_linenums tests/test_extensions/test_highlight.py::TestNoPygmentsCustomLineClass::test_no_pygments_linenums_custom_class_fences tests/test_extensions/test_highlight.py::TestDisabledLinenumsNoPygments::test_global_disable
docs/src/markdown/about/changelog.md pymdownx/highlight.py pymdownx/inlinehilite.py docs/src/markdown/extensions/highlight.md pymdownx/superfences.py
docs/src/markdown/about/changelog.md pymdownx/highlight.py pymdownx/inlinehilite.py docs/src/markdown/extensions/highlight.md pymdownx/superfences.py