Right-click on the module, select "Add framework support...", and check the "Maven" technology.


(This also creates a pom.xml for you to modify.)
If you mean adding source repository elements, I think you need to do that manuallyโnot sure.
Pre-IntelliJ 13 this won't convert the project to the Maven Standard Directory Layout, 13+ it will.
Answer from Dave Newton on Stack OverflowIntelliJ - Convert a Java project/module into a Maven project/module - Stack Overflow
java - How do you "Mavenize" a project using Intellij? - Stack Overflow
Can't add Maven support to existing project
creating new maven managed git controled project using intellij - Stack Overflow
Videos
Right-click on the module, select "Add framework support...", and check the "Maven" technology.


(This also creates a pom.xml for you to modify.)
If you mean adding source repository elements, I think you need to do that manuallyโnot sure.
Pre-IntelliJ 13 this won't convert the project to the Maven Standard Directory Layout, 13+ it will.
A visual for those that benefit from it.

After right-clicking the project name ("test" in this example), select "Add framework support" and check the "Maven" option.
For those that benefit from a visual, as I did:

Essentially, just right-click on the folder. In this example, it's called StackOverFlow and choose Add Framework Support and then check the Maven box. Please note, that this option only exists when you have created a class within the src folder.
Right-click on the module, select "Add framework support...", and check the "Maven" technology. (This also creates a pom.xml for you to modify.)
The title pretty much sums up the issue but I will provide more context here. I am self learning Java so the error could be on me but I can't seem to get IntelliJ to do this.
I have a simple console application that I built and my next step in learning was to add Maven support (not suggested by me). I followed the instructions in the docs to a T but it seems to fail on step 5. Here is step 5:
"IntelliJ IDEA detects a Maven build script and displays a notification suggesting to load a Maven project. Click Load Maven Project. IntelliJ IDEA adds a default POM to the project and generates the standard Maven layout in Project tool window."
I've created the pom.xml file and clicked 'Load Maven Project' on the rare occasions that the button does pop up but I get nothing. It does not generate the standard Maven layout and I run into all kinds of errors when I try to do that manually.
Has anyone else ran into this? I am on version 2025.1.2 on IntelliJ btw.
EDIT: Turns out manually adding the project file structure was a skill issue on my part. I did not correctly import my files with the new files.
IntelliJ still does not automatically create the project structure as stated in their docs though.
You need to right click the java folder and choose the option:
Mark Directory As -> Source Root
If it didn't create java directory, perhaps you didn't chose to create a java maven application when you opened/imported directory with project to idea. Anyways maven's structure is determined and java sources should be in java folder. You have to create a folder manually and mark it as java sources. Go to project settings(alt+ctrl+shift+s) -> Modules -> check your module in sources find your folder and Mark as Sources
