DeFi, short for “decentralized finance,” is a system that makes financial products available on a public decentralized blockchain network that is not regulated by financial intermediaries like banks and national or international administration.
DeFi involves taking traditional elements of the financial system and replacing the middleman with a smart contract. Here smart contracts are automated enforceable agreements running on the blockchain that can execute automatically when certain conditions are met. In other words, you can think of Defi as a system where software written on blockchains makes it possible for buyers, sellers, lenders, and borrowers to interact peer to peer, rather than a financial institution facilitating a transaction.
Currently, Most of the DeFi protocols operate on the Ethereum blockchain, while some are now also hosted on other competing blockchains like the Solana network. Unlike a bank or other financial institution, you do not necessarily require to use a government-issued ID, proof of address, or any other identity proof to use DeFi.

Using DeFi lending, you can lend out cryptocurrency, just like a traditional bank does with fiat currency, and earn interest as a lender. Smart contracts allow developers to create far more sophisticated functionality(application) than simply sending and receiving cryptocurrency. These applications are called decentralized apps, or dapps.
So, dapp simply is an app that is built on decentralized technology, rather than being built and controlled by a single, centralized entity or firm. Many DeFi dapps are already live and available today that allows users to lend out money and earn interest on their crypto, create stablecoins (cryptocurrency whose value is pegged to the US dollar), exchange one asset for another, take out a loan, go long or short assets, as well as carry out automated, advanced investment strategies. DeFi dapps provide you with more control over your money through personal wallets and trading services that explicitly cater to you instead of institutions.

The components of DeFi are quite the same as those for traditional financial ecosystems, meaning it requires stable currencies and a variety of use cases. DeFi components take the form of stablecoins, which is a cryptocurrency whose value is pegged to the US dollar; and services such as crypto exchanges and lending services. Smart contracts, which are at the core of Defi, provide the framework for the functioning of dapps because they encode the terms and activities necessary for the functioning of these services. For instance, a smart contract code can have a specific code that establishes the exact terms and conditions of a loan between individuals. If certain terms or conditions are not met, collateral security could be liquidated. And all this gets conducted by the specific code written in smart contract rather than manually by a bank or other institution.