Set Up User Feedback

Learn how to enable User Feedback in your Android app.

The User Feedback feature allows you to collect user feedback from anywhere inside your application at any time, without needing an error event to occur first.

The User Feedback widget allows users to submit feedback from anywhere inside your application.

To start using the User Feedback widget in your Android application, just start the SDK. A SentryUserFeedbackDialog will be available to be used in your app. For the configuration options, please refer to the User Feedback Widget Configuration[User Feedback Configuration].

Copied
import io.sentry.android.core.SentryUserFeedbackDialog;

// Just instantiate the dialog and show it whenever you want
new SentryUserFeedbackDialog(context).show();

The User Feedback widget integrates seamlessly with Session Replay. When the widget is opened, the SDK buffers up to 30 seconds of the user's session. If feedback is submitted, this replay is sent along with the feedback, allowing you to view both the feedback and the user's actions leading up to the feedback submission.

The User Feedback API allows you to collect user feedback while using your own UI components. You can submit feedback directly using the Sentry.captureFeedback(Feedback) method:

Copied
import io.sentry.Sentry;
import io.sentry.protocol.Feedback;

Feedback feedback = new Feedback("I encountered a bug while using the app.");
feedback.setName("John Doe");
feedback.setContactEmail("john.doe@example.com");
Sentry.captureFeedback(feedback);
Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").