I have imported a DXF file of my house in QGIS. I also included an openstreetmap layer in WGS84 which also displays my house as a square. Naturally, my house from the DXF file is placed in the ocean at coordinate 0, 0. What I want is to project my house in WGS84. How do I proceed? I am looking for something, like to draw a square around my house in the openstreetmap layer to indicate where to project the data. Is this possible in QGIS or should I follow some other approach?
What you are missing is the coordinate of the origin (0,0) of the DXF drawing in degrees. You would have to put up a local coordinate reference system on the origin of the drawing. If you are lucky, the vertical axis of the drawing is in parallel to the North, otherwise you have to apply a rotation too. An oblique mercator projection can deal with that.
Keep in mind that the drawing is most likely in meters and not in degrees, and one degree longitude is not the same distance than one degree latitude (unless you re close to the equator). That's why WGS84 is not the right CRS for your task.
The map at www.openstreetmap.org is not WGS84, but a Pseudo Mercator projection. In reality, Greenland is not as big as it is drawn in Openstreetmap, so you have distortions coming closer to the poles.
You can accomplish it by using the QGIS Vector Bender plugin, which allows you to translate, rotate, scale, and even distort (if necessary) your original DXF layer.
Basically, you will need to provide the plugin with a line layer representing pairs of points (one pair per line) that are the basis of the transformation. For instance, take a corner of the square you mentioned and draw a line from your DXF geometry to the OSM one. Repeat the process with the other corners and click on Run.
If you use 3 or more points, you will need to install dependencies, see here for details.
Here you find the documentation of the plugin, there is even a presentation video to show you how it works.
Note: Normally, you would need first to project your layers to a Projected Coordinate Reference System (PCRS). However, this plugin handles both Geographic CRS and PCRS.