ReCaptcha is used for protecting your form and keeping your website secured from bots and spams.
ReCaptcha uses 2 keys, i.e ReCaptcha Site Key & ReCaptcha Secret Key.
Site Key is integrated with your Form in Front End. While Secret Key is stored in your Backend System.
You have Form which is accepting Name, Email & uploaded files.
There are either 2 possibilities for storing/collecting data,
1) Storing Data in Database(Backend)
2) Collecting Data through Email, SMS or any transmitting medium.
If you are accepting data in some database(backend) and file storage, you already have backend available with you. So you can integrate ReCaptcha in your form.
However, if you are collecting data through Email or SMS, you can integrate One Time Password(OTP) for submitting the form.
Lets Check the both scenario,
ReCaptcha
Your form will have Name, phone, file upload and a hidden reCaptcha field. ReCaptcha field will contain your site Key.
When User will submit form having datas after validating reCaptcha, form data will sent to your backend. Then Recaptcha will Verify Data coming through form and using Secret Key against the Site Key, it will check, if form is found to be tampered in between, ReCaptcha will reject your data. If Verification succeed, you will be get your data. If failed, reCaptcha will deny the request.
Therefore, only legitimate data will come to your server(Backend).
OTP Validation
If you are not using Backend, and collecting data through SMS or Email, then you can integrate email OTP or SMS OTP to validate the form. Therefore, only legitimate data will come to you through forms.
As you are using NextJs, you are most probably using Node(Backend). Try Learning some basics of Backend, then you will easily integrate FrontEnd and BackEnd.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…