{"id":3233,"date":"2025-10-28T16:00:52","date_gmt":"2025-10-28T16:00:52","guid":{"rendered":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/"},"modified":"2025-10-28T16:00:52","modified_gmt":"2025-10-28T16:00:52","slug":"how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10","status":"publish","type":"post","link":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/","title":{"rendered":"How to Execute Scripts and Commands at Login in Ubuntu 25.10"},"content":{"rendered":"<p>Ubuntu 25.10 has discontinued the <em>Startup Applications<\/em> utility, but users can still configure applications, scripts, and commands to launch at login, though the process has become a bit more complex. The GNOME desktop&#8217;s integrated settings now allow users to easily autostart applications through a toggle found in the <em>Settings<\/em> &gt; <em>Applications<\/em> menu. However, this convenient method only works for applications and does not support user-defined commands or scripts, which may be needed for custom tasks.<\/p>\n<p>To set up auto-start for scripts and commands, you can create a <code>.desktop<\/code> file within the <code>~\/.config\/autostart<\/code> directory. If the directory doesn&#8217;t exist, you can create it manually.<\/p>\n<h3>Steps to Autostart Commands in Ubuntu 25.10<\/h3>\n<h4>Step 1: Locate or Create the Autostart Directory<\/h4>\n<ol>\n<li>Open your home folder and check if the <code>~\/.config\/autostart<\/code> directory is present.<\/li>\n<li>If not, create it by navigating to the <code>.config<\/code> directory, right-clicking, and choosing to create a new folder named <code>autostart<\/code> (all lowercase).<\/li>\n<\/ol>\n<p>You can also use the terminal to create this directory quickly:<\/p>\n<pre><code class=\"language-bash\">mkdir -p ~\/.config\/autostart<\/code><\/pre>\n<h4>Step 2: Create Your <code>.desktop<\/code> File<\/h4>\n<p>Using a text editor, create a new <code>.desktop<\/code> file for each command or script you wish to autostart. Here\u2019s a template to follow:<\/p>\n<pre><code class=\"language-plaintext\">[Desktop Entry]Type=ApplicationExec=$HOME\/scripts\/your_script.shHidden=falseName=Your Script NameComment=Description of what the script does<\/code><\/pre>\n<p>Ensure the <code>Exec<\/code> line contains the appropriate command or script path. Here are some examples:<\/p>\n<ul>\n<li>\n<p>For a direct script:<br \/><code>Exec=$HOME\/scripts\/backup.sh<\/code><\/p>\n<\/li>\n<li>\n<p>For simple commands:<br \/><code>Exec=update-manager --install-all<\/code><\/p>\n<\/li>\n<li>\n<p>For more complex commands with delays:<br \/><code>Exec=sh -c &quot;sleep 5; $HOME\/scripts\/myscript.sh&quot;<\/code><\/p>\n<\/li>\n<\/ul>\n<p>If the command needs to be run in a terminal window, add <code>Terminal=true<\/code> to the <code>.desktop<\/code> file.<\/p>\n<h4>Step 3: Save and Test<\/h4>\n<ol>\n<li>Save your file with a <code>.desktop<\/code> extension in the <code>autostart<\/code> folder.<\/li>\n<li>Log out and back in to check if the command or script starts as expected.<\/li>\n<\/ol>\n<h3>Alternatives<\/h3>\n<p>For advanced users, using systemd User Services can provide more control over startup behaviors. However, for most users, <code>.desktop<\/code> files offer a simpler and manageable method to autostart custom scripts and commands.<\/p>\n<p>To modify or delete an autostart, you can change <code>Hidden=false<\/code> to <code>=true<\/code> in the <code>.desktop<\/code> file or remove the file from <code>~\/.config\/autostart\/<\/code>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ubuntu 25.10 has discontinued the Startup Applications utility, but users can still configure applications, scripts, and commands to launch at login, though the process has become a bit more complex. The GNOME desktop&#8217;s integrated settings now allow users to easily autostart applications through a toggle found in the Settings &gt; Applications menu. However, this convenient [&hellip;]<\/p>\n","protected":false},"author":0,"featured_media":3234,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1234,143,920],"tags":[],"class_list":["post-3233","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-autostart-apps","category-how-to","category-ubuntu-25-10"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog\" \/>\n<meta property=\"og:description\" content=\"Ubuntu 25.10 has discontinued the Startup Applications utility, but users can still configure applications, scripts, and commands to launch at login, though the process has become a bit more complex. The GNOME desktop&#8217;s integrated settings now allow users to easily autostart applications through a toggle found in the Settings &gt; Applications menu. However, this convenient [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/\" \/>\n<meta property=\"og:site_name\" content=\"ServerHost Hosting Solutions Blog\" \/>\n<meta property=\"article:published_time\" content=\"2025-10-28T16:00:52+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/\",\"url\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/\",\"name\":\"How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog\",\"isPartOf\":{\"@id\":\"https:\/\/serverhost.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp\",\"datePublished\":\"2025-10-28T16:00:52+00:00\",\"author\":{\"@id\":\"\"},\"breadcrumb\":{\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage\",\"url\":\"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp\",\"contentUrl\":\"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp\",\"width\":2400,\"height\":1260},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/serverhost.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Execute Scripts and Commands at Login in Ubuntu 25.10\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/serverhost.com\/blog\/#website\",\"url\":\"https:\/\/serverhost.com\/blog\/\",\"name\":\"ServerHost Hosting Solutions Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/serverhost.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/","og_locale":"en_US","og_type":"article","og_title":"How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog","og_description":"Ubuntu 25.10 has discontinued the Startup Applications utility, but users can still configure applications, scripts, and commands to launch at login, though the process has become a bit more complex. The GNOME desktop&#8217;s integrated settings now allow users to easily autostart applications through a toggle found in the Settings &gt; Applications menu. However, this convenient [&hellip;]","og_url":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/","og_site_name":"ServerHost Hosting Solutions Blog","article_published_time":"2025-10-28T16:00:52+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/","url":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/","name":"How to Execute Scripts and Commands at Login in Ubuntu 25.10 - ServerHost Hosting Solutions Blog","isPartOf":{"@id":"https:\/\/serverhost.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage"},"image":{"@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage"},"thumbnailUrl":"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp","datePublished":"2025-10-28T16:00:52+00:00","author":{"@id":""},"breadcrumb":{"@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#primaryimage","url":"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp","contentUrl":"https:\/\/serverhost.com\/blog\/wp-content\/uploads\/2025\/10\/c462df3d-4fec-47eb-b42f-ee9729e02bb1.webp","width":2400,"height":1260},{"@type":"BreadcrumbList","@id":"https:\/\/serverhost.com\/blog\/how-to-execute-scripts-and-commands-at-login-in-ubuntu-25-10\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/serverhost.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Execute Scripts and Commands at Login in Ubuntu 25.10"}]},{"@type":"WebSite","@id":"https:\/\/serverhost.com\/blog\/#website","url":"https:\/\/serverhost.com\/blog\/","name":"ServerHost Hosting Solutions Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/serverhost.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/posts\/3233","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/comments?post=3233"}],"version-history":[{"count":0,"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/posts\/3233\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/media\/3234"}],"wp:attachment":[{"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/media?parent=3233"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/categories?post=3233"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/serverhost.com\/blog\/wp-json\/wp\/v2\/tags?post=3233"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}