`application.properties` is the default configuration file for a Quarkus application. It normally lives at `src/main/resources/application.properties` in Maven or Gradle projects. One file can hold settings for Quarkus extensions alongside values defined by the application; added extensions contribute their own available properties. Other configuration locations are possible. section 2.2.2 section 3.2
Use an application-specific property to replace a hard-coded value. For example, add `greeting=Hello configuration`, then inject `greeting` into a REST resource with `@ConfigProperty(name = "greeting")`. The `/hello` response then uses the configured value. Quarkus integrates with the MicroProfile Config API for application access to properties. Reserve the `quarkus.` prefix for built-in settings; use another prefix or name for your own. section 3.2.1 section 3.2
Listing 3.2 Injecting a configured greeting message
import org.eclipse.microprofile.config.inject.ConfigProperty;
...
public class GreetingResource {
@ConfigProperty(name = "greeting")
String greeting;
@GET
@Produces(MediaType.TEXT_PLAIN)
public String hello() {
return greeting;
}
...
The resource shows the configured greeting injected into a field and returned by its HTTP endpoint. section 3.2.1
Choose how and when a setting should take effect:
- At startup, JVM system properties override environment variables, which override `application.properties`. For `my.greeting`, the environment-variable form is `MY_GREETING`; a deployment can change the value without editing the file packaged in the artifact. section 3.2.3
- Use `%prod.` before a property for production-only settings. For example, production OIDC properties can point services to a manually managed Keycloak instance without changing their Dev mode setup. section 6.4.2
- Distinguish runtime settings from build-time settings. `quarkus.kubernetes.*` properties customize generated manifests when the image and manifests are built; changing them at application startup will not alter those manifests. section 11.3.2
Configure a service connection
Replace a REST client's hard-coded base URI with `@RegisterRestClient(configKey = "reservations")`, then set `quarkus.rest-client.reservations.url=http://localhost:8081` in `application.properties`. The client location can now be adjusted through configuration rather than the interface annotation. A localhost value is useful while running services locally but needs reconsideration for cloud deployment. section 11.1.1
In Dev mode, the Dev UI Config Editor lists available extension and application properties, including defaults. Edits persist to `application.properties`, but entries there do not become JVM system properties or environment variables: read application values through the configuration API. For a YAML file instead, add the `quarkus-config-yaml` extension. Extension guides list their available configuration properties. section 3.3.1 section 3.2

