= KeePassXC - Auto-Type
:imagesdir: ../images

// tag::content[]
== Auto-Type
The Auto-Type feature acts like a virtual keyboard to populate data from your entries directly into the corresponding websites or applications that you use. You can use the Auto-Type feature on a global level or entry level. Each entry can be configured to be associated with a particular window title and multiple Auto-Type sequences can be pre-defined and selected upon use.

NOTE: Auto-Type is a completely separate feature from Browser Integration. You do not need to have the KeePassXC browser extension installed in your browser to use Auto-Type.

WARNING: Auto-Type will be disabled when run with a Wayland compositor on Linux. To use Auto-Type in this environment, you must set `QT_QPA_PLATFORM=xcb` or start KeePassXC with the `-platform xcb` command-line flag.

=== Configure Global Auto-Type
You can define a global Auto-Type hotkey that starts the Auto-Type process. To configure the hotkey, perform the following steps:

1. Navigate to _Tools_ -> _Settings_ -> Auto-Type tab *(1)*. Click into the _Global Auto-Type shortcut_ box and press the desired key combination that will trigger the Auto-Type process *(2)*.
+
.Auto-Type settings
image::autotype_settings.png[]
+
You can configure additional Auto-Type settings in this window such as start delay, inter-key typing delay, and matching options. If Auto-Type is not working well for you, try adjusting the default delays.

=== Configure Auto-Type Sequences
Each entry in your database can have multiple Auto-Type sequences associated with various window titles. Simulated key presses can be sent to any other currently open window of your choice (web browser windows, login dialogs boxes, and so on). When the Global Auto-Type hotkey is pressed, KeePassXC will search your database for entries matching the current selected window title.

NOTE: The default Auto-Type sequence is `{USERNAME}{TAB}{PASSWORD}{ENTER}`. This means that it first types the username of the selected entry, then presses the `Tab` key, then types the password of the entry and finally presses the `Enter` key.

To configure Auto-Type sequences for your entries, perform the following steps:

1.	Navigate to the entries list and open the desired entry for editing. Click the _Auto-Type_ item from the left-hand menu bar *(1)*. Press the `+` button *(2)* to add a new sequence entry. Select the desired window using the drop-down menu, or simply type a window title in the box *(3)*. You can use wildcard `*` to match any value (e.g., when a window title contains a filename or website name).
+
.Auto-Type entry sequences
image::autotype_entry_sequences.png[]

2. _(Optional)_ Define a custom Auto-Type sequence for each window title match by selecting the _Use specific sequence for this association_ checkbox. Sequence action codes and field placeholders are detailed in the following table. Beyond the most important ones detailed below, there are additional action codes and placeholders available: xref:UserGuide.adoc#_auto_type_actions[Auto-Type Actions Reference] and xref:UserGuide.adoc#_entry_placeholders[Entry Placeholders Reference]. Action codes and placeholders are not case sensitive.
+
[grid=rows, frame=none, width=90%]
|===
|Placeholder |Description

|{TITLE}    |Entry Title
|{USERNAME} |Username
|{PASSWORD} |Password
|{URL}      |URL
|{NOTES}    |Notes
|{TOTP}     |Current TOTP value (if configured)
|{S:<ATTRIBUTE_NAME>}   |Value for the given attribute name
|===
+
[grid=rows, frame=none, width=90%]
|===
|Action Code |Description

|{TAB}, {ENTER}, {SPACE}, {INSERT}, {DELETE}, {HOME}, {END}, {PGUP}, {PGDN}, {BACKSPACE}, {CAPSLOCK}, {ESC}
|Press the corresponding keyboard key

|{UP}, {DOWN}, {LEFT}, {RIGHT}  |Press the corresponding arrow key
|{LEFTBRACE}, {RIGHTBRACE}      |Press `{` or `}`, respectively
|{<KEY> X}     |Repeat <KEY> X times (e.g., {SPACE 5} inserts five spaces)
|{DELAY=X}     |Set delay between key presses to X milliseconds
|{DELAY X}     |Pause typing for X milliseconds
|{CLEARFIELD}  |Clear the input field
|{PICKCHARS}   |Pick specific password characters from a dialog
|===

=== Performing Global Auto-Type
The global Auto-Type keyboard shortcut is used when you have focus on the window you want to type into. To make use of this feature, you must have previously configured an Auto-Type hotkey.

When you press the global Auto-Type hotkey, KeePassXC searches all unlocked databases for entries that match the focused window title. The Auto-Type selection dialog will appear in the following circumstances: there are no matches found, there are multiple matches found, or the setting "Always ask before performing Auto-Type" is enabled. The selection is remembered for a short while to help retype with the same entry in quick succession.

.Auto-Type sequence selection
image::autotype_selection_dialog.png[,70%]

Perform the selected Auto-Type sequence by double clicking the desired row or pressing _Enter_. Press the up and down arrows to navigate the list. Sequences can be filtered through the text edit field.

.Auto-Type search database
image::autotype_selection_dialog_search.png[,70%]

Search the unlocked databases by activating Search Database radio button. Use the text edit field to issue search queries using the same syntax as database searching.

.Additional Auto-Type choices
image::autotype_selection_dialog_type_menu.png[,70%]

The option to type just the username, password, or current TOTP value is available by right clicking the desired row or expanding the Type Sequence button options.

=== Performing Entry-Level Auto-Type
You can quickly activate the default Auto-Type sequence for a particular entry using Entry-Level Auto-Type. For this operation, the KeePassXC window will be minimized and the Auto-Type sequence occurs in the previously selected window. You can perform Entry-Level Auto-Type from the toolbar icon *(A)*, entry context menu *(B)*, or by pressing `Ctrl+Shift+V`.

WARNING: Be careful when using Entry-Level Auto-Type as you can inadvertently type into the wrong window. For example, a chat window or email.

.Entry-Level Auto-Type
image::autotype_entrylevel.png[]
// end::content[]
