{"id":34003,"date":"2022-05-06T08:21:12","date_gmt":"2022-05-06T08:21:12","guid":{"rendered":"https:\/\/www.arimetrics.com\/glosario-digital\/source-code"},"modified":"2026-09-30T02:14:24","modified_gmt":"2026-09-30T02:14:24","slug":"source-code","status":"publish","type":"encyclopedia","link":"https:\/\/www.arimetrics.com\/en\/digital-glossary\/source-code","title":{"rendered":"Source Code"},"content":{"rendered":"<p><strong><img decoding=\"async\" class=\"boxpad alignright wp-image-63703 size-medium\" src=\"https:\/\/www.arimetrics.com\/wp-content\/uploads\/2022\/05\/codigo_fuente_glosario-300x300.jpg\" alt=\"Representation of a program's source code\" width=\"300\" height=\"300\" srcset=\"https:\/\/www.arimetrics.com\/wp-content\/uploads\/2022\/05\/codigo_fuente_glosario-300x300.jpg 300w, https:\/\/www.arimetrics.com\/wp-content\/uploads\/2022\/05\/codigo_fuente_glosario-150x150.jpg 150w, https:\/\/www.arimetrics.com\/wp-content\/uploads\/2022\/05\/codigo_fuente_glosario.jpg 315w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/>Definition:<\/strong> <strong>Source code<\/strong> is the human-readable expression of a program, component or system in a programming language. It contains instructions and structures that describe behaviour before they are translated, interpreted or otherwise processed for execution.<\/p>\n<p>It may be distributed across one or more files and include comments, modules, declarations and references to dependencies. <strong>Supporting files<\/strong> containing configuration, tests and build rules often accompany it, although these materials perform different roles within a project.<\/p>\n\n<h2>How source code relates to software<\/h2>\n<p>Source code is part of <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/software\">software<\/a>, but the terms are <strong>not synonymous<\/strong>. A product may include code, executable files, libraries, graphical resources, data, documentation and other components needed for operation or distribution.<\/p>\n<p>The same codebase can produce <strong>different results<\/strong> depending on the platform, build options or dependencies. Likewise, having an executable program does not imply access to the original instructions from which it was produced.<\/p>\n<p><strong>Machine code<\/strong> consists of instructions that a processor can execute. Source code, by contrast, is written so that people can read, review and modify it with development tools.<\/p>\n<h2>How source code becomes executable<\/h2>\n<p>The <strong>execution model<\/strong> depends on the language and its environment. Source code is not always compiled in advance or converted directly into a binary file. Common models include:<\/p>\n<ul>\n<li><strong>Compilation:<\/strong> a compiler transforms the code into machine code or another representation before execution.<\/li>\n<li><strong>Interpretation:<\/strong> an interpreter analyses and executes instructions while the program is running.<\/li>\n<li><strong>Intermediate code:<\/strong> some languages produce bytecode or another representation that runs on a virtual machine.<\/li>\n<li><strong>JIT compilation:<\/strong> certain environments translate parts of a program during execution.<\/li>\n<li><strong>Transpilation:<\/strong> a tool converts one language or version into equivalent source code in another.<\/li>\n<\/ul>\n<p>A project may also go through assembly, linking, optimisation, packaging and testing. Together, these tasks form the <strong>build process<\/strong> and may produce applications, libraries, services or files intended for another environment.<\/p>\n<h2>Licensing and access<\/h2>\n<p>The technical ability to read code does not by itself determine what someone may do with it. <strong>Applicable rights<\/strong> to use, modify and distribute it depend on the licence and the law. Common situations include:<\/p>\n<ul>\n<li><strong>Open source:<\/strong> <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/open-source\">open-source<\/a> licences grant rights to use, study, modify and redistribute code under specific conditions. GPL, MIT and Apache are examples with different obligations.<\/li>\n<li><strong>Proprietary software:<\/strong> the rights holder retains exclusive rights and may withhold the source or permit inspection only under limited conditions.<\/li>\n<li><strong>Source available:<\/strong> a project can publish its code without granting all the permissions required by an open-source licence.<\/li>\n<li><strong>Public domain:<\/strong> this is not a licence. It may result from copyright expiry or from waiver and dedication mechanisms where the relevant legal system permits them.<\/li>\n<li><strong>Dual licensing:<\/strong> the same code may be offered under two licences, while an open-core model keeps some components open and others proprietary.<\/li>\n<\/ul>\n<p>Price does not define the licence either. Free or freemium software can be proprietary, while an open-source project may offer paid services. A useful description separates <strong>access and rights<\/strong> from cost.<\/p>\n<h2>Source code in web development<\/h2>\n<p>On the web, browsers receive resources such as <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/html\">HTML<\/a>, <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/css\">CSS<\/a> and JavaScript. These files form part of the <strong>client-side code<\/strong> and can be inspected with browser tools, even when they have been minified or bundled.<\/p>\n<p><strong>Server-side code<\/strong> is not normally delivered to visitors. A site can generate HTML with PHP, Python, Java or other technologies without exposing those instructions. Viewing a page&#8217;s delivered code therefore does not reveal its complete logic, database or internal services.<\/p>\n<p>The <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/frontend\">frontend<\/a> may also be organised with components, preprocessors and bundling tools. The browser receives a <strong>production output<\/strong> that may not correspond line by line with the files maintained by developers.<\/p>\n<h2>Uses in development and maintenance<\/h2>\n<p>Source code is the material that teams work on throughout the <strong>software lifecycle<\/strong>. Its availability supports several tasks:<\/p>\n<ul>\n<li><strong>Review:<\/strong> teams can analyse changes, identify defects and check whether an implementation meets its requirements.<\/li>\n<li><strong>Maintenance:<\/strong> developers can fix errors, update dependencies and adapt a program to new environments.<\/li>\n<li><strong>Version control:<\/strong> platforms such as <a href=\"https:\/\/www.arimetrics.com\/en\/digital-glossary\/github\">GitHub<\/a> record changes, branches and contributions within code repositories.<\/li>\n<li><strong>Auditing:<\/strong> the code provides material for examining quality, privacy or security, although access alone does not guarantee that a program has no vulnerabilities.<\/li>\n<li><strong>Learning:<\/strong> developers can study programming techniques and decisions when the licence permits them to inspect and reuse the material.<\/li>\n<\/ul>\n<p>Preserving the code, its dependencies and its build instructions supports <strong>technical continuity<\/strong>. Without these elements, reproducing a release, fixing a fault or moving a system can be difficult even when a working executable still exists.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Source code expresses a program in a human-readable language. Learn how it relates to software, how it runs, its licensing and its main uses.<\/p>\n","protected":false},"author":33,"featured_media":81181,"template":"","encyclopedia-tag":[1269],"class_list":["post-34003","encyclopedia","type-encyclopedia","status-publish","has-post-thumbnail","hentry","encyclopedia-tag-html-structure"],"_links":{"self":[{"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/encyclopedia\/34003","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/encyclopedia"}],"about":[{"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/types\/encyclopedia"}],"author":[{"embeddable":true,"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/users\/33"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/media\/81181"}],"wp:attachment":[{"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/media?parent=34003"}],"wp:term":[{"taxonomy":"encyclopedia-tag","embeddable":true,"href":"https:\/\/www.arimetrics.com\/en\/wp-json\/wp\/v2\/encyclopedia-tag?post=34003"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}