Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
reCAPTCHA auf einer Demowebsite testen
In diesem Dokument erfahren Sie, wie Sie eine Demowebsite auf Google Cloudbereitstellen. Diese Beispielwebsite ist in reCAPTCHA eingebunden, damit Sie nachvollziehen können, wie reCAPTCHA funktioniert.
Eine Demowebsite bietet Ihnen folgende Möglichkeiten:
Nutzererfahrung mit reCAPTCHA nachvollziehen
Verwenden Sie sie als Referenz, um reCAPTCHA in Ihre eigene Anwendung einzubinden.
Experimentieren Sie mit verschiedenen Frontend- und Backend-Ansätzen, indem Sie den Quellcode der Beispielanwendung bearbeiten.
Sie können eine Demowebsite in einer der folgenden Sprachen bereitstellen: Java, Node.js oder Python.
Für ein Google Cloud -Projekt kann jeweils nur eine Demowebsite bereitgestellt werden.
Hinweise
In the Google Cloud console, on the project selector page,
select or create a Google Cloud project.
In the Principal column, find all rows that identify you or a group that
you're included in. To learn which groups you're included in, contact your
administrator.
For all rows that specify or include you, check the Role column to see whether
the list of roles includes the required roles.
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-09-02 (UTC)."],[],[],null,["# Test reCAPTCHA in a demo website\n================================\n\nThis document shows you how to deploy a demo website on Google Cloud, which is a\nsample website integrated with reCAPTCHA, to\nunderstand how reCAPTCHA works.\n\nA demo website helps you do the following:\n\n- Understand your users' experience with reCAPTCHA.\n- Use as a reference to integrate reCAPTCHA in your own application.\n- Experiment with different frontend and backend approaches by editing the sample application source code.\n\nYou can deploy a demo website in one of the following languages: Java,\nNode.js, or Python.\n\nFor a Google Cloud project, you can deploy only one demo website at\na time.\n| **Note:** When you deploy a demo website, it is deployed on your Cloud Shell VM. The demo site is visible only to you and not to the other members of the project.\n\nBefore you begin\n----------------\n\n1.\n\n\n In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n\n \u003cbr /\u003e\n\n2.\n\n\n Enable the reCAPTCHA Enterprise API.\n\n\n [Enable the API](https://console.cloud.google.com/flows/enableapi?apiid=recaptchaenterprise.googleapis.com)\n\n \u003cbr /\u003e\n\n3.\n\n\n Make sure that you have the following role or roles on the project:\n\n reCAPTCHA Enterprise Admin, reCAPTCHA Enterprise Agent\n\n #### Check for the roles\n\n 1.\n In the Google Cloud console, go to the **IAM** page.\n\n [Go to IAM](https://console.cloud.google.com/projectselector/iam-admin/iam?supportedpurview=project)\n 2. Select the project.\n 3.\n In the **Principal** column, find all rows that identify you or a group that\n you're included in. To learn which groups you're included in, contact your\n administrator.\n\n 4. For all rows that specify or include you, check the **Role** column to see whether the list of roles includes the required roles.\n\n #### Grant the roles\n\n 1.\n In the Google Cloud console, go to the **IAM** page.\n\n [Go to IAM](https://console.cloud.google.com/projectselector/iam-admin/iam?supportedpurview=project)\n 2. Select the project.\n 3. Click person_add **Grant access**.\n 4.\n In the **New principals** field, enter your user identifier.\n\n This is typically the email address for a Google Account.\n\n 5. In the **Select a role** list, select a role.\n 6. To grant additional roles, click add **Add\n another role** and add each additional role.\n 7. Click **Save**.\n\n \u003cbr /\u003e\n\n4. If you have previously deployed a demo website, delete the relevant\n demo key.\n\nDeploy a demo website\n---------------------\n\n1. In the Google Cloud console, go to the demo website page.\n\n [Go to demo website](https://console.cloud.google.com/security/recaptcha/demo)\n2. In the **Language** list, select a language.\n\n The entire deployment process might take about 1 minute.\n3. If prompted, authorize Cloud Shell to make calls using your\n credentials.\n\n4. To navigate to your new demo **Key details** page, click **View site**.\n\n5. To view the demo website, in the **Frontend** card, click\n **View sample web page**.\n\n The demo website opens in a separate tab.\n6. To learn the patterns for integrating\n reCAPTCHA with your website, click through the examples.\n\n7. If you want to make changes to the demo website, do the following:\n\n 1. In the **Key details** page, click **Edit source**.\n 2. In the Cloud Shell Editor, find the required files in the\n **Explorer** and edit them as required.\n\n The saved changes to the source code get reloaded into the demo\n website.\n\n Don't close the Cloud Shell Editor because it closes\n Cloud Shell and stops the demo website.\n\n| **Warning:** Don't use the demo key in a production environment because its configuration is specific to demo environments. For instructions to create a new key, see [Create reCAPTCHA keys for websites](/recaptcha/docs/create-keys-websites).\n\nWhat's next\n-----------\n\n- [Get started with reCAPTCHA](/recaptcha/docs/implementation-workflow)."]]