user135757: How does a node decide whether a transaction is valid and whether to propagate it to other nodes?

Could you please mention some of the basic rules that nodes follow for such a purpose?

user47827: There are consensus rules and policy rules for a transaction to follow. If a transaction doesn't follow all these rules then a node won't allow that transaction to enter into its mempool and won't propagate it to its peers. Policy rules include checking the transaction pays a non-zero transaction fee (above the dust level) and isn't spending from an undefined (soft fork) SegWit version.
Transactions that don't follow policy rules can still make it into a mined block however as a miner may have different policy rules to a node(s) on the network. But a transaction that doesn't follow consensus rules can't be included in a block as other miners and other nodes on the network would reject a block with that consensus invalid transaction in it. Consensus rules check things like the transaction isn't creating new Bitcoin out of thin air (unless a coinbase transaction), that it includes the required signature(s) and isn't encumbered by an unexpired timelock.

135757: <p>How does a node decide whether a transaction is valid and whether to propagate it to other nodes?</p>
<p><a href="https://i.stack.imgur.com/qkPCt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qkPCt.png" alt="enter image description here" /></a></p>
<p>Could you please mention some of the basic rules that nodes follow for such a purpose?</p>
 47827: <p>There are consensus rules and <a href="https://bitcoin.stackexchange.com/questions/100317/what-is-the-difference-between-policy-and-consensus-when-it-comes-to-a-bitcoin-c">policy rules</a> for a transaction to follow. If a transaction doesn't follow all these rules then a node won't allow that transaction to enter into its mempool and won't propagate it to its peers. Policy rules include checking the transaction pays a non-zero transaction fee (above the dust level) and isn't spending from an undefined (soft fork) SegWit version.</p>
<p>Transactions that don't follow policy rules can still make it into a mined block however as a miner may have different policy rules to a node(s) on the network. But a transaction that doesn't follow consensus rules can't be included in a block as other miners and other nodes on the network would reject a block with that consensus invalid transaction in it. Consensus rules check things like the transaction isn't creating new Bitcoin out of thin air (unless a coinbase transaction), that it includes the required signature(s) and isn't encumbered by an unexpired timelock.</p>
