Inicio

Legislación de la República de Chile · Texto vigente
Base legal actualizada al 2026

Toda la ley chilena,
artículo por artículo

Consulta el texto completo y vigente de los códigos, leyes y decretos de Chile. Rápido, claro y sin registro.

Por ejemplo: artículo 159 del Código del Trabajo · Ley 19.947 · pensión de alimentos

34Códigos vigentes
12.400+Leyes
+18.000Decretos
1Constitución
document.addEventListener(`DOMContentLoaded`, function() { function populateDynamicList(querySelector, targetGridId, defaultTag, typeName) { const queryEl = document.querySelector(querySelector); if (!queryEl) return; const links = queryEl.querySelectorAll(`ul.wp-block-post-template li h2 a`); if (links.length === 0) { console.log(`No dynamic pages found for ` + typeName + `. Keeping default hardcoded list.`); return; } const container = document.getElementById(targetGridId); if (!container) return; // Clear the container container.innerHTML = «; links.forEach(link => { const url = link.getAttribute(`href`); const fullTitle = link.textContent.trim(); let tag = defaultTag; let displayTitle = fullTitle; // Parse tag and formatting based on type if (typeName === `ley`) { const numMatch = fullTitle.match(new RegExp(`(Ley|Decreto|DFL) *([0-9]+)`, `i`)); if (numMatch) { tag = numMatch[2].substring(0, 2); } displayTitle = fullTitle.replace(new RegExp(`:`), ` · `); } else if (typeName === `codigo`) { const words = fullTitle.toLowerCase().split(` `).filter(w => w !== `del` && w !== `de` && w !== `de-` && w !== «); let initials = «; words.forEach(w => { if (w.length > 0) initials += w[0].toUpperCase(); }); if (initials.length >= 2) { tag = initials.substring(0, 2); } else if (initials.length === 1) { tag = initials + `C`; } displayTitle = fullTitle; } else if (typeName === `decreto`) { const numMatch = fullTitle.match(new RegExp(`(Ley|Decreto|DFL) *([0-9]+)`, `i`)); if (numMatch) { tag = numMatch[2].substring(0, 2); } else { tag = fullTitle.toUpperCase().startsWith(`DFL`) ? `DFL` : `D`; } displayTitle = fullTitle.replace(new RegExp(`:`), ` · `); } let pathname = url; try { pathname = new URL(url).pathname; } catch(e) {} const itemHtml = ` ${tag} ${displayTitle} ${pathname} `; container.insertAdjacentHTML(`beforeend`, itemHtml); }); console.log(`Successfully loaded ` + links.length + ` dynamic pages into ` + targetGridId); } populateDynamicList(`.dynamic-codes-query`, `home-codes-grid`, `CC`, `codigo`); populateDynamicList(`.dynamic-laws-query`, `home-laws-grid`, `19`, `ley`); populateDynamicList(`.dynamic-decrees-query`, `home-decrees-grid`, `D`, `decreto`); });