Magento 2: How to change layout of the custom module

Paste the code in the layout file..

Path:  Vendorname/Module Name/view/frontend/layout/custom_index_index.xml

 


<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">

 

 

for example-


<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceContainer name="content">
<block class="Vendorname\Module Name\Block\Frontend\Blockname" name="frontend_name" template="frontend/template.phtml">
</block>
</referenceContainer>
</body>
</page>

&nbsp;