With the Spring'23 release, LWC template refs are available now. In order to use this in LWC, we need to enable Lightning Web Security first using the below step: Setup -> Session Settings -> Under the section 'Lightning Web Security' select the checkbox for enabling LWS for LWC. After this, we can use lwc:ref in our code. In this example, we have a textinput and we are getting the label and value using template refs when the input is getting changed. Reference: https://developer.salesforce.com/docs/component-library/documentation/en/lwc/lwc.reference_directives Attached are the screenshots.