How do I programmatically switch to Dark Mode (Dark Theme) in R2025a?

160 visualizaciones (últimos 30 días)
I am running R2025a pre-release. What are the commands to switch to dark mode?

Respuesta aceptada

Mike Croucher
Mike Croucher el 13 de En. de 2025
Editada: Mike Croucher el 13 de En. de 2025
This is supported from R2025a onwards. This is what you need to do
>> s = settings;
>> s.matlab.appearance.MATLABTheme.PersonalValue = "Dark";
  1 comentario
Adam Danz
Adam Danz el 13 de En. de 2025
Editada: Adam Danz el 14 de En. de 2025
And for figures,
theme('dark') % light | auto
% Or
theme(fig,'dark')
% Or
fig = figure(Theme='dark')
% or
fig.Theme = 'dark';

Iniciar sesión para comentar.

Más respuestas (1)

Michelle Hirsch
Michelle Hirsch el 13 de En. de 2025
A few more notes:
  • The default behavior is to match your system theme. So, if your system theme is Dark, MATLAB is dark.
  • There's a setting (aka "preference") for it, too. An easy way to get there is to =just search for something like "dark" in the new search bar:

Categorías

Más información sobre Environment and Settings en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by