Scala Syntax Highlighting in ChatGPT

Currently, when sharing Scala code blocks in ChatGPT using triple backticks and the scala language tag, no syntax highlighting appears β€” even though it works perfectly for Java, Python, etc.

Example

object Hello {
  def main(args: Array[String]): Unit = {
    println("Hello, world!")
  }
}

As you can see, despite using the correct Markdown formatting, the code appears as plain text in the ChatGPT interface.

Why This Matters

Scala is widely used in backend systems, distributed computing, and functional programming. Lack of syntax highlighting makes it harder to read and share Scala code effectively within ChatGPT.

Request

Please consider adding built-in support for Scala syntax highlighting in the ChatGPT chat interface. It would significantly improve the experience for Scala developers.

Thank you for the great tool and continued improvements!

It appears to work for me.

You may still be right though and need to adjust the first prompt to get it to output code blocks?

This is what renders in my browser:


It is a code block but it doesn’t highlights the code with colors like in java for example.

1 Like